-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
new workflow to update snapshot in test apps
- Loading branch information
1 parent
e613bc5
commit ce52e6d
Showing
1 changed file
with
43 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: Pre-Release - Update Test Apps with new Snapshot | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
next_version: | ||
description: 'Next version. Specify <major.minor>, e.g. 6.4 (Do NOT include -SNAPSHOT, will be added automatically)' | ||
required: true | ||
workflow_call: | ||
inputs: | ||
next_version: | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
update-apps: | ||
name: Update Apps Repo | ||
strategy: | ||
matrix: | ||
repo: [ embrace-io/android-sdk-benchmark, embrace-io/android-test-suite ] | ||
timeout-minutes: 60 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Configure git | ||
run: | | ||
git config --global user.name 'embrace-ci[bot]' | ||
git config --global user.email 'embrace-ci@users.noreply.github.com' | ||
git config --global url."https://${{ secrets.CD_GITHUB_USER }}:${{ secrets.CD_GITHUB_TOKEN }}@github.com".insteadOf "https://github.com" | ||
- name: Checkout App | ||
uses: actions/checkout@v4 | ||
with: | ||
repository: ${{ matrix.repo }} | ||
ref: master | ||
token: ${{ secrets.CD_GITHUB_TOKEN }} | ||
|
||
- name: Set next SDK version | ||
run: | | ||
git checkout master | ||
sed -i -r "s#swazzler_version = ([^\']+)#swazzler_version = ${{ github.event.inputs.next_version }}.0-SNAPSHOT#" gradle.properties | ||
git add gradle.properties | ||
git commit -m "CI/CD: set next version: ${{ github.event.inputs.next_version }}.0-SNAPSHOT" | ||
git push |