Conversation
There was a problem hiding this comment.
Pull request overview
Updates the documentation deployment pipeline to publish GitHub Pages from both main and develop, and aligns VitePress configuration with branch-aware deployment settings.
Changes:
- Extend
deploy-docs.ymltriggers tomainanddevelop, add concurrency scoping/cancellation, and pass base path + branch info into the docs build. - Make VitePress
baseconfigurable via env with normalization, and make edit links point to the deployed branch. - Remove legacy Netlify deployment configuration.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
.github/workflows/deploy-docs.yml |
Expands triggers, adds branch-scoped concurrency, configures Pages, and gates deploys to main/develop. |
website/.vitepress/config.mts |
Normalizes base from env and makes edit links branch-aware via DOCS_EDIT_BRANCH. |
netlify.toml |
Removes Netlify build/publish configuration since deployments are now via GitHub Pages. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: read | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| fetch-depth: 0 | ||
|
|
||
| - name: Configure GitHub Pages | ||
| id: pages | ||
| uses: actions/configure-pages@v5 | ||
|
|
There was a problem hiding this comment.
The build job sets permissions: contents: read, but it also runs actions/configure-pages@v5. Job-level permissions override the workflow-level pages: write, so configure-pages may fail to read/compute base_path due to missing Pages permission. Consider adding pages: write (or removing the job-level override) for the build job so steps.pages.outputs.base_path is reliably available.
| return '/' | ||
| } | ||
|
|
||
| return base.endsWith('/') ? base : `${base}/` |
There was a problem hiding this comment.
normalizeBase ensures a trailing slash but doesn't enforce a leading slash. VitePress expects base to start and end with /, so a value like mempalace would normalize to mempalace/ and produce broken asset/route URLs. Consider normalizing to always add a leading / when missing (and still ensure trailing /).
| return base.endsWith('/') ? base : `${base}/` | |
| const withLeadingSlash = base.startsWith('/') ? base : `/${base}` | |
| return withLeadingSlash.endsWith('/') ? withLeadingSlash : `${withLeadingSlash}/` |
This pull request updates the documentation deployment workflow and related configuration to support deployments from both the
mainanddevelopbranches, improves deployment robustness, and simplifies environment management. The key changes are grouped below:GitHub Actions workflow improvements:
.github/workflows/deploy-docs.ymlworkflow now triggers on pushes to bothmainanddevelopbranches and on changes to the workflow file itself. It also enables manual dispatch.group: pages-${{ github.ref }}) and enabling cancellation of in-progress runs.mainordevelopbranches.Documentation configuration enhancements:
website/.vitepress/config.mtsfile now normalizes the docs base path and dynamically sets the edit link branch based on the deployment environment, ensuring correct navigation and edit links for both branches. [1] [2]Cleanup and simplification:
netlify.tomlconfiguration is removed, as deployment is now handled exclusively via GitHub Actions.