docs(samples): add visual walkthroughs and a sidebar-driven website #54
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Docs | |
| # Builds the Docusaurus site in Website/ and publishes it to GitHub Pages. | |
| # Content comes from the package (Documentation/ and Samples~/*/Documentation/) and the root CHANGELOG*.md, | |
| # so any change there rebuilds the site. | |
| on: | |
| push: | |
| branches: [main] | |
| paths: | |
| - 'Website/**' | |
| - 'README.md' | |
| - 'Aspid.FastTools/Packages/tech.aspid.fasttools/Documentation/**' | |
| - 'Aspid.FastTools/Packages/tech.aspid.fasttools/Samples~/*/Documentation/**' | |
| - 'CHANGELOG*.md' | |
| - '.github/workflows/docs.yml' | |
| pull_request: | |
| paths: | |
| - 'Website/**' | |
| - 'README.md' | |
| - 'Aspid.FastTools/Packages/tech.aspid.fasttools/Documentation/**' | |
| - 'Aspid.FastTools/Packages/tech.aspid.fasttools/Samples~/*/Documentation/**' | |
| - 'CHANGELOG*.md' | |
| - '.github/workflows/docs.yml' | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| concurrency: | |
| group: pages | |
| cancel-in-progress: false | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| cache-dependency-path: Website/package-lock.json | |
| - run: npm ci | |
| working-directory: Website | |
| - run: npm run check-readme | |
| working-directory: Website | |
| - run: npm run build | |
| working-directory: Website | |
| - uses: actions/upload-pages-artifact@v3 | |
| if: github.event_name != 'pull_request' | |
| with: | |
| path: Website/build | |
| deploy: | |
| if: github.event_name != 'pull_request' | |
| needs: build | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - id: deployment | |
| uses: actions/deploy-pages@v4 |