diff --git a/.github/action-failure-template.md b/.github/action-failure-template.md new file mode 100644 index 00000000000..e3a448f943b --- /dev/null +++ b/.github/action-failure-template.md @@ -0,0 +1,9 @@ +--- +title: GitHub Actions Workflow failed - {{ env.WORKFLOW_NAME }} +assignees: passy +labels: bug +--- + +The workflow {{ env.WORKFLOW_NAME }} failed. You can see it at + +https://github.com/{{ env.REPOSITORY }}/actions/runs/{{ env.RUN_ID }} diff --git a/.github/workflows/publish-android.yml b/.github/workflows/publish-android.yml index dc6bcd24582..b3813f0c37c 100644 --- a/.github/workflows/publish-android.yml +++ b/.github/workflows/publish-android.yml @@ -17,7 +17,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: set up JDK 1.8 uses: actions/setup-java@v1 with: @@ -54,3 +54,13 @@ jobs: with: created_tag: ${{ github.event.inputs.tag }} args: 'SampleApp-android.apk' + - name: Open issue on failure + if: failure() + uses: JasonEtco/create-an-issue@v2.4.0 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + REPOSITORY: ${{ github.repository }} + RUN_ID: ${{ github.run_id }} + WORKFLOW_NAME: "Publish Android" + with: + filename: .github/action-failure-template.md