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
20 changes: 20 additions & 0 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,23 @@ jobs:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

# A new docs version starts with zero records in Algolia, and contextual
# search filters on it, so the search box returns nothing until a recrawl.
reindex:
needs: deploy
if: github.event_name == 'push'
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Reindex Algolia when a docs version is released
run: |
git diff --name-only ${{ github.event.before }} ${{ github.sha }} \
| grep -qxF versions.json || exit 0
curl -sS -f -X POST \
-u "${{ secrets.ALGOLIA_CRAWLER_USER_ID }}:${{ secrets.ALGOLIA_CRAWLER_API_KEY }}" \
"https://crawler.algolia.com/api/1/crawlers/9bc2ab68-0ce9-4f44-9824-3a48219680b2/reindex"
5 changes: 5 additions & 0 deletions docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,11 @@ const config: Config = {
indexName: "Fishjam",
contextualSearch: true,
searchPagePath: "search",
searchParameters: {
// Without this, generated API headings that are exactly the query
// outrank guides before weight.pageRank is ever consulted.
exactOnSingleWordQuery: "word",
},
insights: false,
askAi: {
assistantId: "49fdf088-e614-4b89-86c2-da8c4b566260",
Expand Down
Loading