-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (47 loc) · 1.53 KB
/
hugo.yml
File metadata and controls
51 lines (47 loc) · 1.53 KB
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
on:
push:
branches: ["master"]
workflow_dispatch:
concurrency:
group: "comparch"
cancel-in-progress: true
defaults:
run:
shell: bash
jobs:
update:
runs-on: ubuntu-22.04
steps:
- name: Install
run: sudo apt-get update && sudo apt-get install nodejs hugo rclone
- name: Checkout
uses: nschloe/action-cached-lfs-checkout@v1
- name: Checkout QtRvSim for manual
uses: actions/checkout@v4
with:
repository: cvut/qtrvsim
path: external-qtrvsim
- name: Setup mdBook
uses: peaceiris/actions-mdbook@v2
with:
mdbook-version: "latest"
- name: Cache NPM dependencies
uses: actions/cache@master
with:
path: themes/geekblog/node_modules
key: ${{ runner.OS }}-npm-cache-${{ hashFiles('themes/geekblog/package-lock.json') }}
- name: Build theme
working-directory: ${{ github.workspace }}/themes/geekblog
run: npm install && npm run build
- name: Build with Hugo
run: hugo
- name: Build QtRvSim Manual
run: |
mdbook build external-qtrvsim/docs/user
mkdir -p public/qtrvsim/manual
cp -a external-qtrvsim/docs/user/book/. public/qtrvsim/manual/
- name: Create ZIP Archive
run: zip -r site.zip public/
- name: Send ZIP to Web for deployment
run: |
curl -X POST -H "Authorization: Bearer ${{ secrets.FtpPass }}" -F "file=@site.zip" http://eval.comparch.edu.cvut.cz:1111/github-actions/update-web