Skip to content
This repository was archived by the owner on Oct 18, 2024. It is now read-only.

Commit 840f8b3

Browse files
mjbond-msftemaf
authored andcommitted
Target the v2.0 rebase-action template
1 parent 980a0dc commit 840f8b3

File tree

1 file changed

+32
-12
lines changed

1 file changed

+32
-12
lines changed

.github/workflows/rebase-trigger.yml

Lines changed: 32 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ on:
55
types: [created]
66

77
jobs:
8-
launchBackportBuild:
8+
setupRebase:
99
runs-on: ubuntu-latest
1010
# GITHUB_TOKEN change from read-write to read-only on 2024-02-01 requires permissions block
1111
# https://docs.opensource.microsoft.com/github/apps/permission-changes/
@@ -15,15 +15,35 @@ jobs:
1515
contents: read
1616
security-events: write
1717
if: github.event.issue.pull_request != '' && contains(github.event.comment.body, '@gitbot rebase')
18-
1918
steps:
20-
- uses: xamarin/[email protected]
21-
with:
22-
pull_request_url: ${{ github.event.issue.pull_request.url }}
23-
comment_author: ${{ github.actor }}
24-
github_repository: ${{ github.repository }}
25-
ado_organization: ${{ secrets.ADO_PROJECTCOLLECTION }}
26-
ado_project: ${{ secrets.ADO_PROJECT }}
27-
rebase_pipeline_id: 13926
28-
ado_build_pat: ${{ secrets.ADO_BUILDPAT }}
29-
github_account_pat: ${{ secrets.SERVICEACCOUNT_PAT }}
19+
- name: Show Comment
20+
shell: pwsh
21+
id: show_comment
22+
run: |
23+
Write-Host "Comment: ${env:COMMENT}"
24+
env:
25+
COMMENT: "${{ github.event.comment.body }}"
26+
27+
launchRebaseBuild:
28+
needs: setupRebase
29+
uses: xamarin/rebase-bot-action/.github/workflows/[email protected]
30+
# GITHUB_TOKEN change from read-write to read-only on 2024-02-01 requires permissions block
31+
# https://docs.opensource.microsoft.com/github/apps/permission-changes/
32+
# https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
33+
permissions:
34+
actions: write
35+
contents: read
36+
security-events: write
37+
id-token: write # The rebase-action template being invoked requires this permission
38+
with:
39+
pull_request_url: ${{ github.event.issue.pull_request.url }}
40+
comment_author: ${{ github.actor }}
41+
github_repository: ${{ github.repository }}
42+
secrets:
43+
azure_tenant_id: ${{ secrets.REBASE_AZURE_TENANT_ID }}
44+
azure_subscription_id: ${{ secrets.REBASE_AZURE_SUBSCRIPTION_ID }}
45+
azure_client_id: ${{ secrets.REBASE_AZURE_CLIENT_ID }}
46+
ado_organization: ${{ secrets.ADO_PROJECTCOLLECTION }}
47+
ado_project: ${{ secrets.ADO_PROJECT }}
48+
rebase_pipeline_id: ${{ secrets.REBASE_PIPELINEID }}
49+
github_account_pat: ${{ secrets.SERVICEACCOUNT_PAT }}

0 commit comments

Comments
 (0)