Skip to content

Commit

Permalink
ci(gh-pages): use actions/deploy-pages action instage of gh-pages b…
Browse files Browse the repository at this point in the history
…ranch
  • Loading branch information
Joxit committed Jan 11, 2024
1 parent b1f92e3 commit bf5178b
Showing 1 changed file with 26 additions and 5 deletions.
31 changes: 26 additions & 5 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,40 @@ on:
branches:
- main

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false

jobs:
gh-pages:
name: gh-pages
environment:
name: gh-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Setup Pages
uses: actions/configure-pages@v4
- uses: actions/setup-node@v2
with:
node-version: "20.x"
- run: npm install
- run: npm run docs
- name: Deploy 🚀
uses: JamesIves/github-pages-[email protected]
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
branch: gh-pages
folder: docs
path: './docs'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

0 comments on commit bf5178b

Please sign in to comment.