forked from doveppp/linuxdo-checkin
-
Notifications
You must be signed in to change notification settings - Fork 0
34 lines (28 loc) · 1.07 KB
/
sync.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
name: Sync Upstream
permissions: write-all # grant write permission
on:
schedule:
- cron: '0 0 * * *' # scheduled for 00:00 every Monday
workflow_dispatch: # trigger manually
jobs:
sync-upstream:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Sync upstream changes
id: sync
uses: aormsby/[email protected]
with:
# REQUIRED 'target_repo_token' exactly like this!
target_repo_token: ${{ secrets.GITHUB_TOKEN }}
target_sync_branch: main
upstream_sync_branch: main
upstream_sync_repo: doveppp/linuxdo-checkin
# Set test_mode true during manual dispatch to run tests instead of the true action!!
test_mode: false
- name: Sync check
if: failure()
run: |
echo "[Error] 由于上游仓库的 workflow 文件变更,导致 GitHub 自动暂停了本次自动更新,你需要手动 Sync Fork 一次。"
exit 1