Migrate GitHub Pages deployment from CircleCI to GitHub Actions #1
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: [master] | |
| permissions: | |
| pages: write | |
| id-token: write | |
| concurrency: | |
| group: pages | |
| cancel-in-progress: false | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: '3.3' | |
| - name: Install AsciiDoctor & Rouge | |
| run: gem install asciidoctor rouge | |
| - name: Build site | |
| run: | | |
| mkdir -p _build/html | |
| asciidoctor -a toc="left" -a toclevels=2 README.adoc -o _build/html/index.html | |
| touch _build/html/.nojekyll | |
| - uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: _build/html | |
| deploy: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - id: deployment | |
| uses: actions/deploy-pages@v4 |