Fix build android build #41
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: Analyze and Build Flutter package | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- v* | |
pull_request: | |
branches: | |
- main | |
tags: | |
- v* | |
jobs: | |
spell-check: | |
uses: VeryGoodOpenSource/very_good_workflows/.github/workflows/spell_check.yml@v1 | |
with: | |
includes: | | |
**/*.{dart,md,yaml} | |
!.dart_tool/**/*.{dart,yaml} | |
.*/**/*.yml | |
modified_files_only: false | |
working_directory: "." | |
static-analyses: | |
runs-on: ubuntu-latest | |
steps: | |
- name: 📚 Git Checkout | |
uses: actions/checkout@v4 | |
- name: 🐦 Setup Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
channel: 'stable' | |
cache: true | |
cache-key: flutter-:os:-:channel:-:version:-:arch:-:hash:-${{ hashFiles('**/pubspec.lock') }} | |
- run: flutter --version | |
- name: 📦 Install Dependencies | |
run: | | |
flutter pub global activate very_good_cli | |
very_good --analytics false | |
very_good packages get --recursive --ignore=${{inputs.package_get_excludes}} | |
- name: ✨ Check Formatting | |
run: dart format --set-exit-if-changed . | |
- name: 🕵️ Analyze | |
run: flutter analyze . | |
- name: 📦 Install dartdoc | |
run: flutter pub global activate dartdoc | |
- name: 📄 Run dartdoc | |
run: dart doc . || fail "dart doc failed" | |
pana: | |
uses: VeryGoodOpenSource/very_good_workflows/.github/workflows/pana.yml@v1 | |
with: | |
min_score: 130 | |
working_directory: "." | |
publish: | |
runs-on: ubuntu-latest | |
needs: | |
[ | |
spell-check, | |
static-analyses, | |
pana, | |
] | |
steps: | |
- name: 📚 Git Checkout | |
uses: actions/checkout@v4 | |
- name: 🐦 Setup Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: ${{inputs.flutter_version}} | |
channel: ${{inputs.flutter_channel}} | |
cache: true | |
- name: 📦 Install Dependencies | |
run: flutter pub get | |
- name: 🔐 Setup Pub Credentials | |
run: | | |
mkdir -p $XDG_CONFIG_HOME/dart | |
echo '${{inputs.pub_credentials}}' > "$XDG_CONFIG_HOME/dart/pub-credentials.json" | |
- name: 🌵 Dry Run | |
run: flutter pub publish --dry-run | |
# - name: 📢 Publish | |
# run: flutter pub publish -f |