Skip to content

Commit 98678ae

Browse files
authored
Update update-links.yml
1 parent cb501b4 commit 98678ae

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

.github/workflows/update-links.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@ name: Update Share Links
33
on:
44
push:
55
paths:
6-
- "*.scripting" # 只监听新增或修改的 .scripting 文件
6+
- "*.scripting"
7+
- "**/*.scripting"
78
branches:
89
- main
9-
workflow_dispatch:
10-
10+
workflow_dispatch: # 支持手动触发
11+
1112
jobs:
1213
build:
1314
runs-on: ubuntu-latest
@@ -16,13 +17,14 @@ jobs:
1617
uses: actions/checkout@v4
1718
with:
1819
fetch-depth: 0
20+
token: ${{ secrets.GITHUB_TOKEN }}
1921

2022
- name: Setup Node.js
2123
uses: actions/setup-node@v4
2224
with:
2325
node-version: 20
2426

25-
- name: Generate links and update README
27+
- name: Generate links
2628
run: node scripts/update_links.js
2729

2830
- name: Commit changes
@@ -32,3 +34,5 @@ jobs:
3234
git add README.md
3335
git commit -m "chore: auto update share links" || echo "No changes"
3436
git push
37+
env:
38+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)