Skip to content

Commit

Permalink
chore: update GHA to deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
ronaldtse committed Jun 25, 2024
1 parent d9b3368 commit a3b216c
Showing 1 changed file with 17 additions and 7 deletions.
24 changes: 17 additions & 7 deletions .github/workflows/generate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ permissions:
id-token: write

concurrency:
group: "pages"
group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }}
cancel-in-progress: true

jobs:
Expand All @@ -22,14 +22,24 @@ jobs:
image: metanorma/metanorma:latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Cache Metanorma assets
uses: actions-mn/cache@v1
uses: actions/checkout@v4
with:
submodules: true

- name: Metanorma generate site
uses: actions-mn/build-and-publish@main
uses: actions-mn/build-and-publish@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
agree-to-terms: true
destination: artifact

deploy:
if: ${{ github.ref_name == github.event.repository.default_branch }}
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

0 comments on commit a3b216c

Please sign in to comment.