From a171703e97a99b7828eed235a6cf7e28609127a8 Mon Sep 17 00:00:00 2001 From: Manuel de la Pena Date: Tue, 17 Jan 2023 11:48:15 -0500 Subject: [PATCH 1/2] [Actions] Add action that will bump the hash used for the unified pipeline. The action will send an event to the sdk-insertions repository that will do the correct steps to bump the version of the android project to be used in the unified pipeline. --- .github/workflows/sdk-insertion-bump.yml | 34 ++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/sdk-insertion-bump.yml diff --git a/.github/workflows/sdk-insertion-bump.yml b/.github/workflows/sdk-insertion-bump.yml new file mode 100644 index 00000000000..90e35083566 --- /dev/null +++ b/.github/workflows/sdk-insertion-bump.yml @@ -0,0 +1,34 @@ +name: Notify release branch change + +on: + # trigger for main and release branches. + push: + branches: + - '*' + +jobs: + pingRemote: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - name: Parse commit + shell: pwsh + id: commit_title + run: | + Write-Host "Commit message is $Env:COMMIT_MESSAGE" + $title = ($Env:COMMIT_MESSAGE -split '\n')[0] + "COMMIT_TITLE=$title" >> $env:GITHUB_OUTPUT + env: + COMMIT_MESSAGE: "${{ github.event.head_commit.message }}" + + - name: 'Update remote repository' + uses: peter-evans/repository-dispatch@v2 + with: + token: ${{ secrets.SERVICEACCOUNT_PAT }} + event-type: 'sdk_insertion' + repository: 'xamarin/sdk-insertions' + client-payload: '{"repository": "xamarin/xamarin-android", "branch": "${{ github.ref_name }}", "commit": "${{ github.sha }}", "commit_message": "${{ steps.commit_title.outputs.COMMIT_TITLE }}"}' + + From 34acd09e7468557d839dd1a7345cc6091df3a266 Mon Sep 17 00:00:00 2001 From: Peter Collins Date: Thu, 19 Jan 2023 11:29:58 -0500 Subject: [PATCH 2/2] Trigger against releaseable branches --- .github/workflows/sdk-insertion-bump.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sdk-insertion-bump.yml b/.github/workflows/sdk-insertion-bump.yml index 90e35083566..1e812f07dfe 100644 --- a/.github/workflows/sdk-insertion-bump.yml +++ b/.github/workflows/sdk-insertion-bump.yml @@ -4,7 +4,8 @@ on: # trigger for main and release branches. push: branches: - - '*' + - main + - 'release/**' jobs: pingRemote: