Skip to content

Commit

Permalink
ci: fix deploy-docs (#71)
Browse files Browse the repository at this point in the history
* ci: imp

* test

* ci: fix

* test

* ci: improved
  • Loading branch information
srdtrk authored Jan 30, 2024
1 parent fcf8e3d commit 9340739
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/check-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ on:
branches:
- main
paths:
- './docs'
- 'docs/**'
- '.github/workflows/check-docs.yml'

jobs:
check-docs-build:
Expand All @@ -20,8 +21,9 @@ jobs:
with:
node-version: 18
cache: npm
cache-dependency-path: docs/package-lock.json

- name: Install dependencies
run: npm ci
run: cd docs && npm ci
- name: Test build website
run: npm run build
run: cd docs && npm run build
7 changes: 4 additions & 3 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,12 @@ jobs:
with:
node-version: 18
cache: npm
cache-dependency-path: docs/package-lock.json

- name: Install dependencies
run: npm ci
run: cd docs && npm ci
- name: Build website
run: npm run build
run: cd docs && npm run build

# Popular action to deploy to GitHub Pages:
# Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus
Expand All @@ -37,7 +38,7 @@ jobs:
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
# Build output to publish to the `gh-pages` branch:
publish_dir: ./build
publish_dir: ./docs/build
# The following lines assign commit authorship to the official
# GH-Actions bot for deploys to `gh-pages` branch:
# https://github.com/actions/checkout/issues/13#issuecomment-724415212
Expand Down

0 comments on commit 9340739

Please sign in to comment.