Skip to content

Commit

Permalink
Handle versioning and fastlane in workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
up2code committed Dec 9, 2023
1 parent 141eb52 commit 5d21a4e
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 3 deletions.
21 changes: 20 additions & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ jobs:

- name: Print architecture
run: uname -m

- name: Get current version
id: increment-version
run: echo "::set-output name=version::$(($BASE_VERSION_CODE + 1))"

- name: Setup Flutter
uses: subosito/flutter-action@v2
Expand Down Expand Up @@ -45,4 +49,19 @@ jobs:
echo "storeFile=./vocadb-release-key.keystore" >> ./android/key.properties
- name: Build appbundle
run: flutter build appbundle --no-tree-shake-icons
run: flutter build appbundle --build-number=${{ steps.increment-version.outputs.version }} --no-tree-shake-icons


- name: Download google-play-service-account.json
run: |
echo "${{ secrets.GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}" > ./android/fastlane/google-play-service-account.json
ls ./android/fastlane -l
- uses: ruby/setup-ruby@v1
with:
ruby-version: '3.0'
bundler-cache: true
- uses: maierj/[email protected]
with:
lane: 'internal'
options: '{ "version_code": ${{ steps.increment-version.outputs.version }} }'
4 changes: 2 additions & 2 deletions android/fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ platform :android do
end

desc "Deploy a new version to the Google Play as Internal track"
lane :internal do
lane :internal do |options|
# https://docs.fastlane.tools/actions/upload_to_play_store/
upload_to_play_store(track: "internal",
version_code:102439,
version_code:options[:version_code],
aab: "../build/app/outputs/bundle/release/app-release.aab")
end

Expand Down

0 comments on commit 5d21a4e

Please sign in to comment.