File tree Expand file tree Collapse file tree 2 files changed +64
-0
lines changed
Expand file tree Collapse file tree 2 files changed +64
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Sync branch incubation
2+ on :
3+ push :
4+ branches :
5+ - main
6+
7+ jobs :
8+ sync-branches :
9+ if : ${{ github.repository == 'opendatahub-io/guardrails-detectors' }}
10+ runs-on : ubuntu-latest
11+ name : Syncing branch incubation
12+ steps :
13+ - name : Checkout
14+ uses : actions/checkout@v5
15+ - name : Opening pull request
16+ id : pull
17+ uses : tretuna/sync-branches@1.4.0
18+ with :
19+ GITHUB_TOKEN : ${{secrets.GITHUB_TOKEN}}
20+ FROM_BRANCH : " main"
21+ TO_BRANCH : " incubation"
22+ - name : Add labels
23+ if : ${{ steps.pull.outputs.PULL_REQUEST_NUMBER != '' }}
24+ uses : actions/github-script@v7
25+ with :
26+ script : |
27+ github.rest.issues.addLabels({
28+ owner: context.repo.owner,
29+ repo: context.repo.repo,
30+ issue_number: ${{steps.pull.outputs.PULL_REQUEST_NUMBER}},
31+ labels: ['bot/sync-incubation', 'tide/merge-method-merge']
32+ });
Original file line number Diff line number Diff line change 1+ name : Sync branch stable
2+ on :
3+ push :
4+ branches :
5+ - incubation
6+
7+ jobs :
8+ sync-branches :
9+ if : ${{ github.repository == 'opendatahub-io/guardrails-detectors' }}
10+ runs-on : ubuntu-latest
11+ name : Syncing branch stable
12+ steps :
13+ - name : Checkout
14+ uses : actions/checkout@v5
15+ - name : Opening pull request
16+ id : pull
17+ uses : tretuna/sync-branches@1.4.0
18+ with :
19+ GITHUB_TOKEN : ${{secrets.GITHUB_TOKEN}}
20+ FROM_BRANCH : " incubation"
21+ TO_BRANCH : " stable"
22+ - name : Add labels
23+ if : ${{ steps.pull.outputs.PULL_REQUEST_NUMBER != '' }}
24+ uses : actions/github-script@v7
25+ with :
26+ script : |
27+ github.rest.issues.addLabels({
28+ owner: context.repo.owner,
29+ repo: context.repo.repo,
30+ issue_number: ${{steps.pull.outputs.PULL_REQUEST_NUMBER}},
31+ labels: ['bot/sync-stable', 'tide/merge-method-merge']
32+ });
You can’t perform that action at this time.
0 commit comments