cloudflare/pint
Publicmirrored from https://github.com/cloudflare/pintAvailable
.github/workflows/pages.yml
53lines · modecode
| 1 | name: Deploy GitHub Pages |
| 2 | |
| 3 | on: |
| 4 | push: |
| 5 | branches: |
| 6 | - main |
| 7 | pull_request: |
| 8 | branches: |
| 9 | - main |
| 10 | workflow_dispatch: |
| 11 | |
| 12 | permissions: |
| 13 | contents: read |
| 14 | pages: write |
| 15 | id-token: write |
| 16 | |
| 17 | concurrency: |
| 18 | group: pages-${{ github.workflow }}-${{ github.ref }} |
| 19 | cancel-in-progress: true |
| 20 | |
| 21 | jobs: |
| 22 | pages: |
| 23 | runs-on: ubuntu-latest |
| 24 | steps: |
| 25 | - name: Checkout |
| 26 | uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 |
| 27 | with: |
| 28 | show-progress: false |
| 29 | |
| 30 | - name: Setup Pages |
| 31 | uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0 |
| 32 | |
| 33 | - name: Build with Jekyll |
| 34 | uses: actions/jekyll-build-pages@44a6e6beabd48582f863aeeb6cb2151cc1716697 # v1.0.13 |
| 35 | with: |
| 36 | source: ./docs |
| 37 | destination: ./_site |
| 38 | |
| 39 | - name: Upload artifact |
| 40 | if: github.event_name != 'pull_request' |
| 41 | uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0 |
| 42 | |
| 43 | deploy: |
| 44 | if: github.event_name != 'pull_request' |
| 45 | environment: |
| 46 | name: github-pages |
| 47 | url: ${{ steps.deployment.outputs.page_url }} |
| 48 | runs-on: ubuntu-latest |
| 49 | needs: pages |
| 50 | steps: |
| 51 | - name: Deploy to GitHub Pages |
| 52 | id: deployment |
| 53 | uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0 |
| 54 | |