Skip to content

Commit

Permalink
Add cd workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
shounakmulay committed Feb 9, 2022
1 parent 2f137b4 commit 8918e95
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 7 deletions.
46 changes: 46 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: CI
on:
push:
branches:
- main
workflow_dispatch:
jobs:
build-android:
name: Deploy Android
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Decode Keystore
id: decode_keystore
uses: timheuer/base64-to-file@v1
with:
fileName: 'keystore/flutter_template_keystore.jks'
encodedString: ${{ secrets.KEYSTORE }}
- name: Build APK
run: scripts/build.sh apk qa --release
env:
RELEASE_STORE_PASSWORD: ${{ secrets.RELEASE_STORE_PASSWORD }}
RELEASE_KEY_ALIAS: ${{ secrets.RELEASE_KEY_ALIAS }}
RELEASE_KEY_PASSWORD: ${{ secrets.RELEASE_KEY_PASSWORD }}
- name: Upload Artifact to App Center
uses: wzieba/AppCenter-Github-Action@v1
with:
appName: shounak-wednesday.is/Flutter-template-test-Android
token: ${{secrets.APP_CENTER_TOKEN}}
group: testers
file: build/app/outputs/flutter-apk/app-qa-release.apk
notifyTesters: true
# build-ios:
# name: Deploy iOS
# runs-on: macos-latest
# steps:
# - uses: actions/checkout@v2
# - uses: subosito/flutter-action@v2
# with:
# channel: 'stable'
# - name: Get Dependencies
# run: flutter pub get
# - name: Run build_runner
# run: flutter pub run build_runner build
# - name: Build iOS
# run: scripts/build.sh ios dev --debug --no-codesign
3 changes: 0 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
name: CI
on:
push:
branches:
- main
pull_request:
jobs:
lint-test-build-android:
Expand Down
24 changes: 20 additions & 4 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,10 @@ android {

signingConfigs {
release {
storeFile file("../keystore/release.keystore")
storePassword System.getenv("RELEASE_STORE_PASSWORD")
keyAlias System.getenv("RELEASE_KEY_ALIAS")
keyPassword System.getenv("RELEASE_KEY_PASSWORD")
storeFile file("../../keystore/flutter_template_keystore.jks")
storePassword "flutter_template_keystore_password"
keyAlias "key0"
keyPassword "flutter_template_keystore_password"
}
}

Expand All @@ -82,6 +82,22 @@ android {
signingConfig signingConfigs.release
}
}

/*
Flutter suggested fix:
┌─ Flutter Fix ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│ This issue appears to be https://github.com/flutter/flutter/issues/58247. │
│ Fix this issue by adding the following to the file /Users/shounakmulay/Documents/Work/Flutter/flutter_template/android/app/build.gradle: │
│ android { │
│ lintOptions { │
│ checkReleaseBuilds false │
│ } │
│ } │
└──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
*/
lintOptions {
checkReleaseBuilds false
}
}

flutter {
Expand Down

0 comments on commit 8918e95

Please sign in to comment.