Bump the pub group across 1 directory with 4 updates #57
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: Autoformat and Lint | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
autoformat: | |
name: Autoformat and Lint | |
if: github.actor != 'dependabot[bot]' | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: 🛎 Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.head_ref }} | |
token: ${{ secrets.WORKFLOW_COMMIT }} | |
- name: 🎯 Setup Dart | |
uses: dart-lang/setup-dart@v1 | |
- name: 🐦 Setup Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
channel: 'stable' | |
cache: true | |
- name: 📦 Get dependencies | |
run: flutter pub get | |
- name: 🤖 Build dart files | |
run: dart run build_runner build | |
- name: 📝 Format Code | |
run: dart format . | |
- name: 🔧 Fix Linting Issues | |
run: dart fix --apply | |
- name: ✅ Commit code format changes | |
if: github.ref != 'refs/heads/main' | |
uses: stefanzweifel/git-auto-commit-action@v5 | |
with: | |
commit_message: "Autoformat code" | |
- name: 🔍 Lint Flutter | |
run: flutter analyze |