-
Notifications
You must be signed in to change notification settings - Fork 2
58 lines (52 loc) · 1.44 KB
/
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: GitHub Pages
on:
push:
branches:
- main # Set a branch to deploy
- synolib2 # publish on change in either branch
permissions:
contents: write
jobs:
build-pages:
concurrency: ci-${{ github.ref }} # Recommended if you intend to make multiple deployments in quick succession.
runs-on: ubuntu-22.04
steps:
# main / old:
- name: 'Checkout main branch'
uses: actions/checkout@v3
with:
ref: main
- name: Setup Deno
uses: denoland/setup-deno@v1
with:
deno-version: v1.x
- name: prepare
run: |
mkdir build
cp index.html build/
- run: deno bundle SynonymGroup.ts build/synonym-group.js
- run: cp SynonymGroup.ts build/
# synolib2 / new:
- name: 'Checkout synolib2 branch'
uses: actions/checkout@v3
with:
ref: synolib2
path: 'synolib2'
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: Draw the rest of the owl
run: |
cd synolib2
npm ci
npm run example build
mkdir ../build/next
cp ./example/index.* ../build/next/
cd ..
- name: Deploy to GitHub Pages
uses: JamesIves/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: gh-pages
folder: build