-
Notifications
You must be signed in to change notification settings - Fork 4
41 lines (41 loc) · 1.15 KB
/
on-push-main.yml
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
name: on Push Main
on:
push:
branches:
- main
jobs:
unit-test:
name: Unit Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Use flutter-action
uses: subosito/flutter-action@v2
with:
flutter-version: "3.0.1"
- name: Install pub packages
run: dart pub get
- name: Run Unit Tests
run: dart run test --coverage=coverage
- name: Extract lcov file
run: |
dart pub global activate coverage
dart pub global run coverage:format_coverage --lcov --report-on=lib --in=coverage --out=coverage/lcov.info
- name: Send coverage to Codecov
uses: codecov/codecov-action@v3
with:
directory: coverage
release:
needs: [unit-test]
name: Release
runs-on: ubuntu-latest
steps:
- name: Run Release Please
uses: google-github-actions/release-please-action@v3
with:
token: ${{ secrets.CUSTOM_GITHUB_TOKEN }}
release-type: dart
package-name: poker
bump-minor-pre-major: true
bump-patch-for-minor-pre-major: true