-
Notifications
You must be signed in to change notification settings - Fork 105
43 lines (36 loc) · 1.14 KB
/
gh-pages.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
name: Build and Deploy Docs
on:
push:
branches:
- main
pull_request:
jobs:
build-publish:
runs-on: ubuntu-latest
permissions:
contents: write
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
steps:
- name: Checkout
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: Setup Node.js 18.x
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1
with:
node-version: 18.x
cache: npm
- name: Install dependencies
run: npm install
- name: Audit dependencies
if: ${{ github.actor != 'dependabot[bot]' && github.actor != 'renovate[bot]' }}
run: npm audit
- name: Build website
run: npm run build
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@373f7f263a76c20808c831209c920827a82a2847 # v3.9.3
if: ${{ github.ref == 'refs/heads/main' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
user_name: brave-builds[bot]
user_email: [email protected]