Store times by event/course/gender only, persist across age changes #23
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 | |
| paths: | |
| - 'index.html' | |
| - 'swim_time_standards.json' | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: true | |
| jobs: | |
| deploy: | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Verify required files exist | |
| run: | | |
| for f in index.html swim_time_standards.json; do | |
| if [ ! -f "$f" ]; then | |
| echo "::error ::Required file '$f' not found. Aborting deployment." | |
| exit 1 | |
| fi | |
| done | |
| - name: Prepare publish directory | |
| run: | | |
| rm -rf .publish | |
| mkdir -p .publish | |
| cp index.html .publish/ | |
| cp swim_time_standards.json .publish/ | |
| # show what will be published (helpful in logs) | |
| ls -la .publish | |
| - name: Setup Pages | |
| uses: actions/configure-pages@v4 | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: .publish | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |