Skip to content

Commit b4ab7eb

Browse files
committed
CI: Action - Code Analysis
1 parent 8b71392 commit b4ab7eb

File tree

1 file changed

+55
-0
lines changed

1 file changed

+55
-0
lines changed

.github/workflows/code-analysis.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Code Analysis
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches:
7+
- master
8+
paths-ignore:
9+
- '**.md'
10+
pull_request:
11+
branches:
12+
- master
13+
paths-ignore:
14+
- '**.md'
15+
16+
jobs:
17+
code-analysis:
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v4
21+
- uses: subosito/flutter-action@v2
22+
with:
23+
channel: 'stable'
24+
- name: Prepare dependencies
25+
run: |
26+
flutter --version
27+
flutter pub get
28+
- name: Check Dart code formatting
29+
run: |
30+
dart format . -o none --set-exit-if-changed
31+
- name: Analyze Dart code
32+
run: |
33+
flutter analyze .
34+
- name: Generate dartdoc
35+
run: |
36+
dart pub global activate dartdoc
37+
dart pub global run dartdoc .
38+
test:
39+
needs: [code-analysis]
40+
runs-on: ubuntu-latest
41+
strategy:
42+
matrix:
43+
flutter-version: ['']
44+
steps:
45+
- uses: actions/checkout@v4
46+
- uses: subosito/flutter-action@v2
47+
with:
48+
channel: 'stable'
49+
flutter-version: ${{ matrix.flutter-version }}
50+
- name: Prepare dependencies
51+
run: |
52+
flutter --version
53+
flutter pub get
54+
- name: Test
55+
run: flutter test

0 commit comments

Comments
 (0)