-
Notifications
You must be signed in to change notification settings - Fork 17
34 lines (29 loc) · 800 Bytes
/
Copy pathbuild.yaml
File metadata and controls
34 lines (29 loc) · 800 Bytes
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
# .github/workflows/build.yml
name: build_script
on:
push:
branches: ['main']
paths:
- 'src/**'
- 'build.js'
workflow_dispatch:
jobs:
build:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- name: checkout code
uses: actions/checkout@v6
- name: setup Node.js
uses: actions/setup-node@v6
with:
node-version: '24'
- name: run build script
run: node build.js
- name: commit and push changes
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add Script/mihomoScript.js
git diff --cached --quiet || (git commit -m "build: 更新脚本" && git push)