Skip to content

Commit 5d2d09e

Browse files
[pre-commit.ci lite] apply automatic fixes
1 parent d6024fa commit 5d2d09e

File tree

2 files changed

+40
-38
lines changed

2 files changed

+40
-38
lines changed
Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,30 @@
11
name: "Automatically mark PRs to sync"
22

33
on:
4-
pull_request:
5-
types:
6-
- opened
4+
pull_request:
5+
types:
6+
- opened
77

88
jobs:
9-
labeler:
10-
if: github.event.pull_request.user.type != 'Bot'
11-
permissions:
12-
pull-requests: write
9+
labeler:
10+
if: github.event.pull_request.user.type != 'Bot'
11+
permissions:
12+
pull-requests: write
1313

14-
runs-on: ubuntu-latest
15-
steps:
16-
- name: Add "sync" label to PR
17-
run: gh pr edit "$PR_URL" --add-label sync --repo "$PR_REPO"
18-
env:
19-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
20-
PR_URL: ${{ github.event.pull_request.html_url }}
21-
PR_REPO: ${{ github.repository }}
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Add "sync" label to PR
17+
run: gh pr edit "$PR_URL" --add-label sync --repo "$PR_REPO"
18+
env:
19+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
20+
PR_URL: ${{ github.event.pull_request.html_url }}
21+
PR_REPO: ${{ github.repository }}
2222

23-
- name: Comment on PR to explain sync label
24-
run: gh pr comment "$PR_URL" --body "This pull request has been marked to **automatically sync** to its base branch. You can **disable** this behavior by removing the `sync` label." --repo "$PR_REPO"
25-
env:
26-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27-
PR_URL: ${{ github.event.pull_request.html_url }}
28-
PR_REPO: ${{ github.repository }}
23+
- name: Comment on PR to explain sync label
24+
run: gh pr comment "$PR_URL" --body "This pull request has been marked to **automatically
25+
sync** to its base branch. You can **disable** this behavior by removing the `sync`
26+
label." --repo "$PR_REPO"
27+
env:
28+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
PR_URL: ${{ github.event.pull_request.html_url }}
30+
PR_REPO: ${{ github.repository }}
Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
name: "Automatically enable auto-merge on PRs"
22

33
on:
4-
pull_request_target:
5-
types:
6-
- opened
7-
- ready_for_review
8-
branches:
9-
- main
4+
pull_request_target:
5+
types:
6+
- opened
7+
- ready_for_review
8+
branches:
9+
- main
1010

1111
jobs:
12-
enable-automerge:
13-
if: github.event.pull_request.draft == false
14-
permissions:
15-
pull-requests: write
12+
enable-automerge:
13+
if: github.event.pull_request.draft == false
14+
permissions:
15+
pull-requests: write
1616

17-
runs-on: ubuntu-latest
18-
steps:
19-
- name: Enable auto-merge for the PR
20-
run: gh pr merge "$PR_URL" --auto --squash
21-
env:
22-
GH_TOKEN: ${{ secrets.PR_AUTO_UPDATE_TOKEN }}
23-
PR_URL: ${{ github.event.pull_request.html_url }}
17+
runs-on: ubuntu-latest
18+
steps:
19+
- name: Enable auto-merge for the PR
20+
run: gh pr merge "$PR_URL" --auto --squash
21+
env:
22+
GH_TOKEN: ${{ secrets.PR_AUTO_UPDATE_TOKEN }}
23+
PR_URL: ${{ github.event.pull_request.html_url }}

0 commit comments

Comments
 (0)