2023-01-26 14:40:19 +00:00
|
|
|
name: Static Code Analysis
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
pull_request:
|
|
|
|
push:
|
|
|
|
branches: [main]
|
|
|
|
|
2023-02-19 16:44:53 +00:00
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
2023-01-26 14:40:19 +00:00
|
|
|
jobs:
|
|
|
|
mobile-dart-analyze:
|
|
|
|
name: Run Dart Code Analysis
|
|
|
|
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Checkout code
|
2023-09-06 01:50:22 +00:00
|
|
|
uses: actions/checkout@v4
|
2023-01-26 14:40:19 +00:00
|
|
|
|
|
|
|
- name: Setup Flutter SDK
|
|
|
|
uses: subosito/flutter-action@v2
|
|
|
|
with:
|
2024-05-16 15:58:02 +00:00
|
|
|
channel: 'stable'
|
2024-05-28 11:15:28 +00:00
|
|
|
flutter-version-file: ./mobile/pubspec.yaml
|
2023-01-26 14:40:19 +00:00
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: dart pub get
|
|
|
|
working-directory: ./mobile
|
|
|
|
|
|
|
|
- name: Run dart analyze
|
|
|
|
run: dart analyze --fatal-infos
|
|
|
|
working-directory: ./mobile
|
2024-02-19 04:30:24 +00:00
|
|
|
|
|
|
|
- name: Run dart format
|
|
|
|
run: dart format lib/ --set-exit-if-changed
|
|
|
|
working-directory: ./mobile
|
|
|
|
|
2023-11-19 16:04:44 +00:00
|
|
|
# Enable after riverpod generator migration is completed
|
|
|
|
# - name: Run dart custom lint
|
|
|
|
# run: dart run custom_lint
|
|
|
|
# working-directory: ./mobile
|