-
Notifications
You must be signed in to change notification settings - Fork 1
44 lines (39 loc) · 959 Bytes
/
node.js.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: Node.js CI
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
# Sets the GITHUB_TOKEN permissions to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./js
steps:
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
cache: 'npm'
cache-dependency-path: ./js/package-lock.json
- run: npm ci
- run: npx vite build --base=/surf/
- name: Setup Pages
uses: actions/configure-pages@v4
with:
#token: ${{ secrets.GITHUB_TOKEN }}
enablement: true
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload dist folder
path: './js/dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4