Skip to content

Commit bc564e6

Browse files
committed
fix: use PAT for PR creation and activate cron schedule
- Use PAT_TOKEN instead of default GITHUB_TOKEN to allow PR creation - Add push trigger on workflow file to activate the cron schedule - Remove auto-merge step Made-with: Cursor
1 parent 6fc73a4 commit bc564e6

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

.github/workflows/sync-upstream.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@ name: Sync from upstream java.evolved
22

33
on:
44
schedule:
5-
# Weekly on Monday at 06:00 UTC
65
- cron: '0 6 * * 1'
7-
workflow_dispatch: # Manual trigger from Actions tab
6+
push:
7+
branches: [main]
8+
paths: ['.github/workflows/sync-upstream.yml']
9+
workflow_dispatch:
810

911
permissions:
1012
contents: write
@@ -16,6 +18,8 @@ jobs:
1618
steps:
1719
- name: Checkout this repo
1820
uses: actions/checkout@v4
21+
with:
22+
token: ${{ secrets.PAT_TOKEN }}
1923

2024
- name: Clone upstream source
2125
run: |
@@ -59,6 +63,7 @@ jobs:
5963
if: steps.changes.outputs.has_changes == 'true'
6064
uses: peter-evans/create-pull-request@v6
6165
with:
66+
token: ${{ secrets.PAT_TOKEN }}
6267
commit-message: "chore: sync references from upstream (${{ steps.upstream.outputs.sha }})"
6368
title: "Sync: Update patterns from java.evolved (${{ steps.upstream.outputs.date }})"
6469
body: |

0 commit comments

Comments
 (0)