-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Specified Flutter environment version in pubspec.yaml - Add version constraint to `custom_lint` and `riverpod_lint` - Add check.yml workflow - Add build.yml workflow
- Loading branch information
Showing
4 changed files
with
96 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
name: Build release tag | ||
on: | ||
push: | ||
tags: | ||
- "v*" | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
name: Create ${{ matrix.os }} build | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
target: [Linux] | ||
include: | ||
- os: ubuntu-latest | ||
target: Linux | ||
build_target: linux | ||
build_path: build/linux/x64/release/bundle | ||
asset_name: linux_amd64 | ||
asset_extension: .tar.gz | ||
asset_content_type: application/gzip | ||
fail-fast: false | ||
steps: | ||
- name: Install Flutter | ||
uses: subosito/flutter-action@v2 | ||
with: | ||
channel: stable | ||
flutter-version-flie: pubspec.yaml | ||
- name: Install Linux dependencies | ||
if: matrix.target == 'Linux' | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y clang cmake ninja-build libgtk-3-dev libstdc++-12-dev | ||
- uses: actions/checkout@v2 | ||
- run: | | ||
flutter config --enable-linux-desktop | ||
flutter config --no-analytics | ||
dart --disable-analytics | ||
flutter config --no-enable-android | ||
flutter config --no-enable-web | ||
- run: flutter doctor -v | ||
- run: flutter pub get | ||
- run: dart fix --apply --code=unnecessary_final | ||
- run: flutter build -v ${{ matrix.build_target }} --release | ||
- name: Compress build for Linux | ||
if: matrix.target == 'Linux' | ||
run: tar czf $GITHUB_WORKSPACE/yatta_${{ matrix.build_target }}${{ matrix.asset_extension }} * | ||
working-directory: ${{ matrix.build_path }} | ||
- name: Upload the artifact to release | ||
uses: svenstaro/upload-release-action@v2 | ||
with: | ||
repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
release_name: Release ${{ github.ref_name }} | ||
file: yatta_${{ matrix.build_target }}${{ matrix.asset_extension }} | ||
tag: ${{ github.ref }} | ||
asset_name: yatta_${{ github.ref_name }}_${{ matrix.asset_name }}${{ matrix.asset_extension }} | ||
overwrite: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: Code check | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
types: | ||
- opened | ||
- reopened | ||
- synchronize | ||
|
||
jobs: | ||
format: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: subosito/flutter-action@v2 | ||
with: | ||
channel: stable | ||
flutter-version-flie: pubspec.yaml | ||
- name: Update dependencies | ||
run: flutter pub get | ||
- name: Disable analytics | ||
run: | | ||
flutter config --no-analytics | ||
dart --disable-analytics | ||
- name: Remove custom lint # https://github.com/invertase/dart_custom_lint/issues/228 | ||
run: sed -i '/custom_lint/d' analysis_options.yaml | ||
- name: Format | ||
run: dart format --set-exit-if-changed lib | ||
- name: Analyze | ||
run: flutter analyze lib |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -890,4 +890,4 @@ packages: | |
version: "1.0.3" | ||
sdks: | ||
dart: ">=3.3.3 <4.0.0" | ||
flutter: ">=3.19.0" | ||
flutter: ">=3.19.6" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters