Skip to content

Commit

Permalink
fix: github action script (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
hugoleborso authored Jan 24, 2024
1 parent 21d7dde commit e1614b5
Showing 1 changed file with 19 additions and 7 deletions.
26 changes: 19 additions & 7 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ permissions:
pages: write
id-token: write

# Allow one concurrent deployment
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
Expand All @@ -28,29 +28,41 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: "18"
cache: "pnpm"

- name: Install pnpm
run: npm install -g pnpm

- name: Install dependencies
run: pnpm install
- name: Build with Next.js
run: pnpm run --filter documentation build
- name: Upload artifact
working-directory: ./documentation

- name: Build Docusaurus site
run: pnpm run build
working-directory: ./documentation

- name: Upload artifact for deployment
uses: actions/upload-pages-artifact@v3
with:
path: ./documentation/build

# Deployment job
deploy:
needs: build
runs-on: ubuntu-latest
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

- name: Print page URL
run: echo "Deployed to ${PAGES_URL}"
env:
PAGES_URL: ${{ steps.deployment.outputs.page_url }}

0 comments on commit e1614b5

Please sign in to comment.