Skip to content

Commit

Permalink
Updated github pages publishing workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
CraftingDragon007 committed Apr 27, 2024
1 parent dad4eda commit 9c57800
Showing 1 changed file with 20 additions and 6 deletions.
26 changes: 20 additions & 6 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,23 +19,37 @@ jobs:
url: ${{ steps.deployment.outputs.page_url }}

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Setup Node.js environment
uses: actions/setup-node@v3.4.1
uses: actions/setup-node@v4.0.2
with:
node-version: 16
node-version: 20

- name: Build palaten_api spec
run: npx redoc-cli build -o build/openapi/palaten_api/index.html openapi/palaten_api.yaml

- name: Build Vuepress
run: cd docs && npm install && npm run build && mv src/.vuepress/dist/* ../build

- name: Archive artifact
shell: sh
if: runner.os == 'Linux'
run: |
echo ::group::Archive artifact
tar \
--dereference --hard-dereference \
--directory "./build" \
-cvf "$RUNNER_TEMP/artifact.tar" \
--exclude=.git \
--exclude=.github \
.
echo ::endgroup::
- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v1.0.3
uses: actions/upload-pages-artifact@v3.0.1
with:
path: build/
path: ${{ runner.temp }}/artifact.tar

- name: Deploy GitHub Pages site
uses: actions/deploy-pages@v1.0.8
uses: actions/deploy-pages@v4.0.5

0 comments on commit 9c57800

Please sign in to comment.