ci(cypress): add support file for e2e tests #10
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: Deploy to GitHub Pages | |
| on: | |
| push: | |
| branches: [ "main" ] # change if your default branch differs | |
| workflow_dispatch: | |
| # Baseline permissions; deploy job gets the extra perms it needs. | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| name: Collect static files | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| # Avoid Jekyll processing on GitHub Pages (good safety default) | |
| - name: Add .nojekyll | |
| run: touch .nojekyll | |
| # Optional: ensure an index exists (fail fast if not) | |
| - name: Verify index.html | |
| run: | | |
| test -f index.html || (echo "index.html not found at repo root" && exit 1) | |
| # Optional: SPA fallback (copies index.html to 404.html). | |
| # Remove this step if you don't want SPA-style routing. | |
| - name: Create SPA 404 fallback | |
| run: cp -f index.html 404.html | |
| - name: Configure Pages | |
| uses: actions/configure-pages@v5 | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| # Your site is at the repo root | |
| path: "." | |
| deploy: | |
| name: Deploy to GitHub Pages | |
| needs: build | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| permissions: | |
| pages: write | |
| id-token: write | |
| steps: | |
| - name: Deploy | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |