Skip to content

Commit 0391c2e

Browse files
authored
Create updateDirectory.yml
1 parent f70f55f commit 0391c2e

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Update Directory Sitemap
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
run-script:
10+
runs-on: ubuntu-latest
11+
if: github.actor != 'github-actions[bot]'
12+
steps:
13+
- name: Checkout repository
14+
uses: actions/checkout@v4
15+
16+
- name: Set up Python
17+
uses: actions/setup-python@v5
18+
with:
19+
python-version: "3.12"
20+
21+
- name: Run Script
22+
run: python ./backend/html-directory-generator.py
23+
24+
- name: Commit and push changes
25+
run: |
26+
git config user.name "github-actions[bot]"
27+
git config user.email "github-actions[bot]@users.noreply.github.com"
28+
git add .
29+
git commit -m "Update directory sitemap" || echo "No changes to commit"
30+
git push
31+
env:
32+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)