APM Play Store Release #105
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: APM Manual AAB Release | |
on: | |
workflow_dispatch: | |
jobs: | |
buildAAB: | |
runs-on: ubuntu-latest | |
name: build AAB | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: python version_bump.py | |
run: | | |
python ./scripts/version_bump.py | |
- name: commit | |
run: | | |
git config --global user.email [email protected] | |
git config --global user.name lovegaoshi | |
git commit -m "build: release version bump" -a | |
- name: Get branch name | |
run: | | |
# Short name for current branch. For PRs, use target branch (base ref) | |
GIT_BRANCH=${GITHUB_BASE_REF:-${GITHUB_REF#refs/heads/}} | |
echo "GIT_BRANCH=$GIT_BRANCH" >> $GITHUB_ENV | |
- name: Get current date | |
id: date | |
run: echo "date=$(date +'%Y-%m-%d')" >> $GITHUB_OUTPUT | |
- name: set up JDK 18 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: 18 | |
distribution: temurin | |
- name: Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '18' | |
- name: Setup Yarn | |
uses: threeal/[email protected] | |
- name: 'Create env file' | |
run: | | |
echo "${{ secrets.ENV_FILE }}" > .env | |
echo "APPSTORE=true" >> .env | |
echo "TRACKING=true" >> .env | |
echo "${{ secrets.SENTRY_PROPERTIES }}" > ./android/sentry.properties | |
- name: alias yarn.cmd to yarn | |
run: alias yarn.cmd="yarn" | |
- name: Add Build Sign Keys | |
run: | | |
git submodule update --init --recursive | |
echo "${{ secrets.RELEASE_SIGN_PWD }}" >> ./android/gradle.properties | |
- name: python fixHTTP | |
run: | | |
python ./scripts/fixHTTP.py | |
- name: Build Sign jks | |
id: write_file | |
uses: timheuer/[email protected] | |
with: | |
fileName: 'noxupload.jks' | |
fileDir: './android/app' | |
encodedString: ${{ secrets.SIGNED_KEY_BASE64 }} | |
- name: Install dependencies | |
uses: nick-fields/retry@v3 | |
with: | |
timeout_minutes: 10 | |
max_attempts: 10 | |
command: yarn install; yarn postinstall | |
- name: clean generated builds | |
run: rm -rf android/app/build/generated/ | |
- name: gradle build AAB | |
run: cd android && chmod +x gradlew && ./gradlew bundleRelease | |
- name: Push changes to master | |
uses: ad-m/github-push-action@master | |
- uses: r0adkll/upload-google-play@v1 | |
with: | |
serviceAccountJsonPlainText: ${{ secrets.GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }} | |
packageName: com.noxplay.noxplayer | |
releaseFiles: android/app/build/outputs/bundle/release/app-release.aab | |
track: internal | |
changesNotSentForReview: true |