forked from divinevideo/divine-mobile
-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (40 loc) · 1.18 KB
/
mobile_ci.yaml
File metadata and controls
50 lines (40 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
name: Mobile CI
on:
push:
branches: [main]
pull_request:
branches: [main]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
name: Mobile CI
runs-on: ubuntu-latest
defaults:
run:
working-directory: mobile/
steps:
- uses: actions/checkout@v4
- name: 🐦 Setup Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: "3.41.1"
channel: "stable"
cache: true
- name: 📦 Install dependencies
run: flutter pub get
- name: 🔨 Verify generated files are up-to-date
run: |
dart run build_runner build --delete-conflicting-outputs
if [ -n "$(git status --porcelain)" ]; then
echo "⚠️ Generated files are out of date. Please run 'dart run build_runner build' and commit the changes."
git diff --name-only
exit 1
fi
- name: ✨ Check formatting
run: dart format --output=none --set-exit-if-changed lib test
- name: 🕵️ Analyze code
run: flutter analyze lib test
- name: 🚀 Run tests
run: flutter test