jekyll-gh-pages.yml 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. # Sample workflow for building and deploying a Jekyll site to GitHub Pages
  2. name: Build GitHub Pages website
  3. on:
  4. # Runs on pushes targeting the default branch
  5. push:
  6. branches: ["dev"]
  7. # Allows you to run this workflow manually from the Actions tab
  8. workflow_dispatch:
  9. # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
  10. permissions:
  11. contents: read
  12. pages: write
  13. id-token: write
  14. # Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
  15. # However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
  16. concurrency:
  17. group: "pages"
  18. cancel-in-progress: true
  19. jobs:
  20. # Build job
  21. build:
  22. runs-on: ubuntu-latest
  23. steps:
  24. - name: Checkout
  25. uses: actions/checkout@v4
  26. with:
  27. submodules: true
  28. fetch-depth: 1
  29. - name: Copy README.md into place
  30. run: |
  31. rm ./website/README.md
  32. cp ./README.md ./website/README.md
  33. - name: Setup Pages
  34. uses: actions/configure-pages@v3
  35. - name: Build with Jekyll
  36. uses: actions/jekyll-build-pages@v1
  37. with:
  38. source: ./website
  39. destination: ./_site
  40. - name: Upload artifact
  41. uses: actions/upload-pages-artifact@v2
  42. # Deployment job
  43. deploy:
  44. environment:
  45. name: github-pages
  46. url: ${{ steps.deployment.outputs.page_url }}
  47. runs-on: ubuntu-latest
  48. needs: build
  49. steps:
  50. - name: Deploy to GitHub Pages
  51. id: deployment
  52. uses: actions/deploy-pages@v2