[ANDROID] Add auto upload to play store
This commit is contained in:
@@ -114,6 +114,28 @@ jobs:
|
||||
name: mapping-${{ matrix.format.type }}
|
||||
path: androidApp/build/outputs/mapping/
|
||||
|
||||
- name: Set up Ruby
|
||||
if: matrix.format.type == 'aab'
|
||||
uses: ruby/setup-ruby@v1
|
||||
with:
|
||||
ruby-version: '3.3'
|
||||
|
||||
- name: Install fastlane
|
||||
if: matrix.format.type == 'aab'
|
||||
run: gem install fastlane -NV
|
||||
|
||||
- name: Write Play Store service account JSON
|
||||
if: matrix.format.type == 'aab'
|
||||
env:
|
||||
GOOGLE_SERVICE_ACCOUNT_JSON: ${{ secrets.GOOGLE_SERVICE_ACCOUNT_JSON }}
|
||||
run: echo "$GOOGLE_SERVICE_ACCOUNT_JSON" > play-service-account.json
|
||||
|
||||
- name: Upload AAB to Play Store internal track
|
||||
if: matrix.format.type == 'aab'
|
||||
run: |
|
||||
AAB_PATH=$(ls androidApp/build/outputs/bundle/release/*.aab | head -n 1)
|
||||
fastlane android internal aab:"$AAB_PATH" json_key:play-service-account.json
|
||||
|
||||
release:
|
||||
needs: build
|
||||
permissions:
|
||||
|
||||
@@ -76,6 +76,24 @@ jobs:
|
||||
with:
|
||||
name: 'mapping-${{ matrix.format.type }}'
|
||||
path: wearOsApp/build/outputs/mapping/
|
||||
- name: Set up Ruby
|
||||
if: matrix.format.type == 'aab'
|
||||
uses: ruby/setup-ruby@v1
|
||||
with:
|
||||
ruby-version: '3.3'
|
||||
- name: Install fastlane
|
||||
if: matrix.format.type == 'aab'
|
||||
run: gem install fastlane -NV
|
||||
- name: Write Play Store service account JSON
|
||||
if: matrix.format.type == 'aab'
|
||||
env:
|
||||
GOOGLE_SERVICE_ACCOUNT_JSON: '${{ secrets.GOOGLE_SERVICE_ACCOUNT_JSON }}'
|
||||
run: echo "$GOOGLE_SERVICE_ACCOUNT_JSON" > play-service-account.json
|
||||
- name: Upload AAB to Play Store internal track
|
||||
if: matrix.format.type == 'aab'
|
||||
run: |
|
||||
AAB_PATH=$(ls wearOsApp/build/outputs/bundle/release/*.aab | head -n 1)
|
||||
fastlane android internal aab:"$AAB_PATH" json_key:play-service-account.json
|
||||
release:
|
||||
needs: build
|
||||
permissions:
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
default_platform(:android)
|
||||
|
||||
platform :android do
|
||||
desc "Upload AAB to Google Play internal testing track"
|
||||
lane :internal do |options|
|
||||
upload_to_play_store(
|
||||
track: 'internal',
|
||||
aab: options[:aab],
|
||||
package_name: 'com.kgurgul.cpuinfo',
|
||||
json_key: options[:json_key],
|
||||
skip_upload_apk: true,
|
||||
skip_upload_metadata: true,
|
||||
skip_upload_changelogs: true,
|
||||
skip_upload_images: true,
|
||||
skip_upload_screenshots: true,
|
||||
release_status: 'draft'
|
||||
)
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user