-
Notifications
You must be signed in to change notification settings - Fork 0
ci: Update documentation workflow to support VitePress #179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -1,37 +1,60 @@ | ||||||
| name: docs | ||||||
| permissions: | ||||||
| contents: write | ||||||
| contents: read | ||||||
|
|
||||||
| on: | ||||||
| push: | ||||||
| tags: | ||||||
| - "v*" | ||||||
| branches: | ||||||
| - main | ||||||
|
|
||||||
| concurrency: | ||||||
| group: "pages" | ||||||
| cancel-in-progress: false | ||||||
|
|
||||||
| env: | ||||||
| EM_CACHE_FOLDER: 'emsdk-cache' | ||||||
|
|
||||||
| jobs: | ||||||
| docs: | ||||||
| build: | ||||||
| runs-on: ubuntu-latest | ||||||
|
|
||||||
| steps: | ||||||
| - uses: actions/checkout@v6 | ||||||
|
|
||||||
| - name: recovery tag information | ||||||
| run: git fetch --tags --force | ||||||
| - uses: actions/setup-node@v6 | ||||||
| with: | ||||||
| node-version: 'latest' | ||||||
| cache: 'npm' | ||||||
|
|
||||||
| - uses: astral-sh/setup-uv@v7 | ||||||
| - uses: actions/cache@v5 | ||||||
| with: | ||||||
| python-version: '3.14' | ||||||
| enable-cache: true | ||||||
| path: ${{ env.EM_CACHE_FOLDER }} | ||||||
| key: docs-em-cache-${{ runner.os }} | ||||||
|
|
||||||
| - name: install dependencies | ||||||
| run: uv sync --locked --extra docs | ||||||
| - uses: pyodide/setup-emsdk@v15 | ||||||
| with: | ||||||
| actions-cache-folder: ${{ env.EM_CACHE_FOLDER }} | ||||||
|
|
||||||
| - name: configure git | ||||||
| run: | | ||||||
| git config --global user.name "github-actions[bot]" | ||||||
| git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" | ||||||
| - name: dependencies | ||||||
| run: npm ci | ||||||
|
|
||||||
| - name: build docs | ||||||
| run: uv run mike deploy --push --update-aliases --alias-type=redirect ${GITHUB_REF#refs/tags/} latest | ||||||
| - name: build | ||||||
| run: npm run docs | ||||||
|
|
||||||
| - name: set default | ||||||
| run: uv run mike set-default --push latest | ||||||
| - uses: actions/upload-pages-artifact@v3 | ||||||
| with: | ||||||
| path: .vitepress/dist | ||||||
|
||||||
| path: .vitepress/dist | |
| path: docs/.vitepress/dist |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The node-version value 'latest' is not a valid version specifier for actions/setup-node. This action expects a specific version number (e.g., '20', '22', '24') or a semantic version range (e.g., '20.x'). Using 'latest' will likely cause the workflow to fail. Consider using a specific Node.js version like '24' to match the other workflows in this repository.