forked from loic-sharma/BaGet
-
Notifications
You must be signed in to change notification settings - Fork 56
44 lines (38 loc) · 1.09 KB
/
deploy_docs.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: Deploy Docs to GitHub Pages
on:
push:
branches:
- main
paths:
- 'docs/**'
- '.github/workflows/deploy_docs.yml'
jobs:
deploy:
runs-on: ubuntu-latest
defaults:
run:
working-directory: docs
steps:
- name: Checkout
uses: actions/checkout@v4.1.1
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: yarn
cache-dependency-path: '**/yarn.lock'
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Build the Docusaurus site
run: yarn build
- name: Deploy to GitHub Pages
if: success()
uses: peaceiris/actions-gh-pages@v3
with:
deploy_key: ${{ secrets.DOCS_DEPLOY_KEY }}
external_repository: 'bagetter/bagetter.github.io'
publish_dir: ./docs/build
publish_branch: main
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
commit_message: ${{ github.event.head_commit.message }}