-
Notifications
You must be signed in to change notification settings - Fork 9
39 lines (33 loc) · 944 Bytes
/
DocsNav.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
35
36
37
38
39
name: Rebuild docs with newest navbar
on:
# 3:25 AM UTC every Sunday -- choose an uncommon time to avoid
# periods of heavy GitHub Actions usage
schedule:
- cron: '25 3 * * 0'
# Whenever needed
workflow_dispatch:
permissions:
contents: write
jobs:
update-navbar:
runs-on: ubuntu-latest
steps:
- name: Checkout gh-pages branch
uses: actions/checkout@v4
with:
ref: gh-pages
- name: Insert navbar
uses: TuringLang/actions/DocsNav@main
with:
doc-path: '.'
- name: Commit and push changes
run: |
if [[ -n $(git status -s) ]]; then
git config user.name github-actions[bot]
git config user.email github-actions[bot]@users.noreply.github.com
git add -A
git commit -m "Update navbar (automated)"
git push
else
echo "No changes to commit"
fi