-
Notifications
You must be signed in to change notification settings - Fork 1
68 lines (55 loc) · 1.93 KB
/
release.yaml
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
name: Flutter Application GitHub Release
on: workflow_dispatch
permissions:
contents: write
jobs:
proxima-app-release:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Get Version From Project
run: echo "VERSION=$(grep 'version:' pubspec.yaml | awk '{print $2}')" >> $GITHUB_ENV
- name: Check that tag does not already exist
run: |
if [ $(git tag -l "v${{ env.VERSION }}") ]; then
exit 1;
fi
- name: Setup Flutter SDK
uses: subosito/flutter-action@v2
with:
channel: stable
flutter-version-file: pubspec.yaml
cache: true
- name: Install Flutter Dependencies
run: |
flutter config --no-analytics --no-cli-animations
flutter --version
flutter pub get
- name: Import API Keys
env:
API_KEYS: ${{ secrets.API_KEYS }}
run: echo "$API_KEYS" > api_keys.json
- name: Import Release Certificate
env:
B64_RELEASE_KEYSTORE: ${{ secrets.B64_RELEASE_KEYSTORE }}
RELEASE_KEYSTORE_PROPERTIES: ${{ secrets.RELEASE_KEYSTORE_PROPERTIES }}
run: |
mkdir android/app/keystore
echo "$B64_RELEASE_KEYSTORE" | base64 --decode > android/app/keystore/release.jks
echo "$RELEASE_KEYSTORE_PROPERTIES" > android/key.properties
- name: Flutter Build APK
run: ./scripts/build
- name: Setup git-cliff Changelog
uses: kenji-miyake/setup-git-cliff@v1
- name: Generate Changelog
run: git cliff --unreleased --tag v${{ env.VERSION }} --topo-order -o
- name: GitHub Release
uses: softprops/action-gh-release@v2
with:
name: Proxima v${{ env.VERSION }}
tag_name: v${{ env.VERSION }}
files: build/Proxima*.apk
body_path: CHANGELOG.md