Skip to content

Commit

Permalink
update master workflow to be able to build release bundle
Browse files Browse the repository at this point in the history
  • Loading branch information
RafaO committed Aug 1, 2024
1 parent 8b1bce7 commit 5413007
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/master-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,25 @@ jobs:
# Get flutter dependencies.
- run: flutter pub get

# Generate the keystore file
- name: Decode keystore file
env:
CERTIFICATE_BASE64: ${{ secrets.STORE_FILE_CONTENT }}
run: echo $CERTIFICATE_BASE64 | base64 --decode > android/app/my-keystore.jks

- name: Create temporary key.properties
run: |
echo "storeFile=my-keystore.jks" > android/key.properties
echo "storePassword=${{ secrets.STORE_PASSWORD }}" >> android/key.properties
echo "keyAlias=${{ secrets.KEY_ALIAS }}" >> android/key.properties
echo "keyPassword=${{ secrets.KEY_PASSWORD }}" >> android/key.properties
# Generate the .env file
- name: Generate .env file
env:
SPOTIFY_CLIENT_ID: ${{ secrets.SPOTIFY_CLIENT_ID }}
run: echo "spotify_client_id=SPOTIFY_CLIENT_ID" > .env

# Build Android release
- run: flutter build appbundle --release

Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ Here are the first steps to get started if you want to use this template as base
- Change package name
- Create Firebase app [instructions](https://firebase.google.com/docs/flutter/setup)
- Add secrets to your Github repository [instructions](https://github.com/marketplace/actions/firebase-app-distribution):
- STORE_PASSWORD
- KEY_ALIAS
- KEY_PASSWORD
- FIREBASE_ANDROID_APP_ID
- FIREBASE_TOKEN
- SERVICE_ACCOUNT_JSON. Used to upload the Android app to Google Play. Please check [this](https://developers.google.com/android-publisher/getting_started#:~:text=Google%20Play%20Console.-,Go%20to%20the%20API%20access%20page%20on%20the%20Google%20Play,Google%20Play%20Console%2C%20click%20Done.) for instructions.
Expand Down

0 comments on commit 5413007

Please sign in to comment.