diff --git a/.github/PULL_REQUEST_TEMPLATE b/.github/PULL_REQUEST_TEMPLATE index 35934de05..ead5583ea 100644 --- a/.github/PULL_REQUEST_TEMPLATE +++ b/.github/PULL_REQUEST_TEMPLATE @@ -7,7 +7,9 @@ - [ ] **Accessibility**: The code in this PR follows [accessibility best practices](https://github.com/mozilla-mobile/shared-docs/blob/master/android/accessibility_guide.md) or does not include any user facing features. In addition, it includes a screenshot of a successful [accessibility scan](https://play.google.com/store/apps/details?id=com.google.android.apps.accessibility.auditor&hl=en_US) to ensure no new defects are added to the product. ### To download an APK when reviewing a PR: -1. click on Show All Checks, -2. click Details next to "Taskcluster (pull_request)" after it appears and then finishes with a green checkmark, -3. click on the "Fenix - assemble" task, then click "Run Artifacts". -4. the APK links should be on the left side of the screen, named for each CPU architecture +The PR runs an Android build check (`run-build`) that builds a `forkRelease` variant of the app. If it succeeds, then we upload the apks (signed with debug keys) via Github actions. +We also generate a comment with some instructions and a link to help you find the downloads. You can also follow the instructions below: +1. Click Details next to "run-build (pull_request_target)" after it finishes with a green checkmark. +2. Click the "Artifacts" drop-down near the top right of the page. +3. The apk links should be present in the drop-down menu. You can click on the suitable CPU architecture to download a zipped apk file. +4. Unzip the file and install the apk. diff --git a/.github/imgs/download-artifacts-screenshot.png b/.github/imgs/download-artifacts-screenshot.png index 1397841d9..fff039553 100644 Binary files a/.github/imgs/download-artifacts-screenshot.png and b/.github/imgs/download-artifacts-screenshot.png differ diff --git a/.github/workflows/android-build-pr.yml b/.github/workflows/android-build-pr.yml index acf9888b2..4230a6d43 100644 --- a/.github/workflows/android-build-pr.yml +++ b/.github/workflows/android-build-pr.yml @@ -6,6 +6,7 @@ on: jobs: run-build: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.title), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -48,7 +49,7 @@ jobs: message: | ### Download the built apks You can download the apks built by Github actions after the CI checks pass. - Please go to the checks page for this PR to find the zipped apk files under the artifacts drop-down, as seen in the example screenshot below. + Please go to the checks page for this PR to find the zipped apk files under the artifacts drop-down, as seen in the example screenshot below. repo-token: ${{ secrets.GITHUB_TOKEN }} @@ -56,6 +57,7 @@ jobs: run-testDebug: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.title), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -74,6 +76,7 @@ jobs: run-detekt: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.title), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -97,6 +100,7 @@ jobs: run-ktlint: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.title), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -115,6 +119,7 @@ jobs: run-lintDebug: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.title), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 diff --git a/.github/workflows/android-build.yml b/.github/workflows/android-build.yml index ec283180e..1e5bbb4c0 100644 --- a/.github/workflows/android-build.yml +++ b/.github/workflows/android-build.yml @@ -6,6 +6,7 @@ on: jobs: run-build: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -46,6 +47,7 @@ jobs: run-testDebug: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -64,6 +66,7 @@ jobs: run-detekt: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -87,6 +90,7 @@ jobs: run-ktlint: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 @@ -105,6 +109,7 @@ jobs: run-lintDebug: runs-on: ubuntu-latest + if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')" steps: - name: Checkout repository uses: actions/checkout@v2 diff --git a/README.md b/README.md index 5f773be97..2faab0e95 100644 --- a/README.md +++ b/README.md @@ -86,6 +86,13 @@ Developers are especially welcome, wanted, and needed. We encourage you to participate in this open source project. We love Pull Requests, Bug Reports, ideas, (security) code reviews or any other kind of positive contribution. +### How to skip CI checks for PRs + +If you want to skip Github CI checks in a PR, please add the following to the PR title exactly: `[skip ci]`. +Also, please include the exact phrase `[skip ci]` in every commit message. This is to avoid Travis CI checks as well as skipping Github CI checks after merging the commits to the `fork` branch. + +This is useful to do **if** you are sure that your changes do not effect the app's code (ex: changes to `README.md`). + ## I want to file an issue! Great! We encourage you to participate in this open source project. We love Pull Requests, Bug Reports, ideas, (security) code reviews or any other kind of positive contribution.