New Version 0.3.0 #61
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
name: flutter build | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["main"] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: "3.13.2" | |
channel: "stable" | |
cache: true | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: "^1.21.0" | |
- name: compile mage | |
run: go mod download && go run magefiles/cmd/mage.go -compile ../mage | |
- name: disable telemetry | |
run: flutter --disable-telemetry | |
- name: Install dependencies and code generation | |
run: ./mage PubGlobalUpgrade PubGet CreateI18nSynthetic BuildRunner CreateVersion CreateI18n | |
- name: Format code generation | |
run: | | |
find -name "*.g.dart" -exec dart format --line-length=120 "{}" "+" | |
find -name "*.freezed.dart" -exec dart format --line-length=120 "{}" "+" | |
find -name "translations*.dart" -exec dart format --line-length=120 "{}" "+" | |
- name: Verify formatting | |
run: dart format --line-length=120 --output=none --set-exit-if-changed . | |
- name: Check licenses | |
run: lic_ck check-licenses -c lic_ck.yaml -i | |
- name: Analyze project source | |
run: dart analyze --fatal-infos | |
- name: Run tests | |
run: flutter test |