-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
089b94b
commit f75efbe
Showing
1 changed file
with
36 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,36 @@ | ||
name: react-native-android-build-apk | ||
on: | ||
pull_request: | ||
branches: | ||
- dev | ||
jobs: | ||
install-and-test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install npm dependencies | ||
run: | | ||
npm install | ||
build-android: | ||
needs: install-and-test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install npm dependencies | ||
run: | | ||
npm install | ||
- name: Build Android Release | ||
run: | | ||
cd android && ./gradlew assembleRelease | ||
- name: Upload Artifact | ||
uses: actions/upload-artifact@v1 | ||
with: | ||
name: app-release.apk | ||
path: android/app/build/outputs/apk/release/ | ||
- name: Post Artifact Link in PR Comment | ||
uses: unsplash/comment-on-pr@master | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
msg: "Android APK build is complete. You can download the release APK here: [Download APK](https://github.com/${{ github.repository }}/actions/artifacts)" | ||
check_for_duplicate_msg: false |