Skip to content

Update Documentation Search Index #4

Update Documentation Search Index

Update Documentation Search Index #4

name: Update Documentation Search Index
on:
# once a month (14:14 at the 14th of the month)
schedule:
- cron: "14 14 14 * *"
# allow triggering manually
workflow_dispatch: {}
permissions:
contents: write
#───────────────────────────────────────────────────────────────────────────────
jobs:
build:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: "21.x"
- name: Update Documentation Search Index
run: |
node ./.github/doc-search-cache/re-index-documentation.mjs > ./.github/doc-search-cache/cache.json
[[ -z "$(git status)" ]] && exit 0
git add ./.github/doc-search-cache/cache.json
git commit -m "chore: Updated documentation index" --author="🤖 Automated GitHub Action<cron@job>"
git push