Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 58 additions & 0 deletions .github/workflows/update-docs-index.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Docs

on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}
cancel-in-progress: false

permissions:
contents: write

jobs:
update:
name: Rebuild documentation search index
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Check out code
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
with:
ref: main
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
with:
python-version: "3.12"

- name: Set up uv
uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7.6.0
with:
version: "0.11.22"

- name: Install dependencies
run: uv sync --frozen --group dev

- name: Rebuild documentation index
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
run: uv run --group dev python scripts/build_docs_index.py

- name: Commit updated index
run: |
git add src/mcp_server_appwrite/data/docs_index.npz \
src/mcp_server_appwrite/data/docs_index_meta.json
if git diff --cached --quiet; then
echo "Documentation index is already up to date"
exit 0
fi

git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git commit -m "chore: refresh documentation search index"
git pull --rebase origin main
git push origin HEAD:main
Binary file modified src/mcp_server_appwrite/data/docs_index.npz
Binary file not shown.
2 changes: 1 addition & 1 deletion src/mcp_server_appwrite/data/docs_index_meta.json

Large diffs are not rendered by default.

Loading