Skip to content

Commit b972d64

Browse files
authored
Initial commit
0 parents  commit b972d64

File tree

10 files changed

+573
-0
lines changed

10 files changed

+573
-0
lines changed
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Update Worktree and Trigger Workflow
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
7+
schedule:
8+
- cron: '0 0 * * *'
9+
10+
workflow_dispatch:
11+
12+
jobs:
13+
trigger:
14+
runs-on: ubuntu-latest
15+
permissions: write-all
16+
17+
steps:
18+
- name: Checkout repository
19+
uses: actions/checkout@v4
20+
with:
21+
fetch-depth: 0
22+
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
23+
24+
- name: Set up Python
25+
uses: actions/setup-python@v5
26+
with:
27+
python-version: '3.12'
28+
29+
- name: Download and run generate_worktree_info.py
30+
run: |
31+
# Download the script
32+
curl -o /tmp/generate_worktree_info.py https://raw.githubusercontent.com/HITSZ-OpenAuto/repos-management/main/scripts/generate_worktree_info.py
33+
34+
# Make it executable and run it
35+
chmod +x /tmp/generate_worktree_info.py
36+
python3 /tmp/generate_worktree_info.py
37+
38+
- name: Trigger workflow in hoa-moe
39+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
40+
env:
41+
GITHUB_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
42+
run: |
43+
curl -X POST \
44+
-H "Accept: application/vnd.github.v3+json" \
45+
-H "Authorization: token $GITHUB_TOKEN" \
46+
https://api.github.com/repos/HITSZ-OpenAuto/hoa-moe/actions/workflows/course.yaml/dispatches \
47+
-d '{"ref":"main"}'

.hoa/worktree.json

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
{
2+
".github/workflows/trigger-workflow.yml": {
3+
"size": 2057,
4+
"time": 1751869046,
5+
"hash": "85fbff3de5afcf2124fac31f211595a0ab694b20"
6+
},
7+
".hoa/worktree.json": {
8+
"size": 1242,
9+
"time": 1751869059,
10+
"hash": "3d18a1ec6d2e4a6a26908398e85958a1b0956919"
11+
},
12+
"LICENSE": {
13+
"size": 20844,
14+
"time": 1713079986,
15+
"hash": "a0d2af2ebc903391e6ffc7b5ba7560b0aadd1488"
16+
},
17+
"README.md": {
18+
"size": 1487,
19+
"time": 1737523002,
20+
"hash": "13f98d4661b257fd4aff49e0ccf7730d666bedfd"
21+
},
22+
"assignments/.gitkeep": {
23+
"size": 0,
24+
"time": 1737523002,
25+
"hash": "13f98d4661b257fd4aff49e0ccf7730d666bedfd"
26+
},
27+
"exams/.gitkeep": {
28+
"size": 0,
29+
"time": 1737523002,
30+
"hash": "13f98d4661b257fd4aff49e0ccf7730d666bedfd"
31+
},
32+
"labs/.gitkeep": {
33+
"size": 0,
34+
"time": 1737523002,
35+
"hash": "13f98d4661b257fd4aff49e0ccf7730d666bedfd"
36+
},
37+
"notes/.gitkeep": {
38+
"size": 0,
39+
"time": 1737523002,
40+
"hash": "13f98d4661b257fd4aff49e0ccf7730d666bedfd"
41+
},
42+
"slides/.gitkeep": {
43+
"size": 0,
44+
"time": 1737523002,
45+
"hash": "13f98d4661b257fd4aff49e0ccf7730d666bedfd"
46+
},
47+
"tag.txt": {
48+
"size": 448,
49+
"time": 1735985429,
50+
"hash": "d47d59dfc95f01b519648dc31907909736f9e5c0"
51+
}
52+
}

0 commit comments

Comments
 (0)