-
Notifications
You must be signed in to change notification settings - Fork 0
83 lines (74 loc) · 2.09 KB
/
mik0486.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
name: Compile LaTeX - MIK0486
on:
push:
branches:
- master
paths:
- 'mik0486/**'
- 'shared/**'
pull_request:
branches:
- master
paths:
- 'mik0486/**'
- 'shared/**'
workflow_dispatch:
jobs:
check-markdown:
runs-on: ubuntu-latest
continue-on-error: true
steps:
- uses: actions/checkout@v3
- uses: DavidAnson/[email protected]
with:
fix: true
globs: 'mik0486/**/*.md'
build-latex:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Fake display for plantuml
- name: Set up Xvfb
run: |
sudo apt-get install -y xvfb
sudo Xvfb :99 -ac -screen 0 1024x768x8 &
export DISPLAY=:99
- name: Compiling LaTeX documents
uses: xu-cheng/latex-action@v3
with:
root_file: main.tex
working_directory: mik0486/src
args: -pdf -halt-on-error -synctex=1 -interaction=nonstopmode --shell-escape --enable-write18
extra_system_packages: 'inkscape openjdk17'
docker_image: ghcr.io/xu-cheng/texlive-full:20240315
- name: Upload LaTeX documents to artifacts
uses: actions/upload-artifact@v4
if: success()
with:
name: MIK0486-Thesis
path: mik0486/src/main.pdf
if-no-files-found: error
- name: Upload LaTeX documents to server
uses: appleboy/[email protected]
with:
host: ${{ secrets.SSH_HOST }}
username: root
key: ${{ secrets.SSH_PRIVATE_KEY }}
port: 22
source: mik0486/src/main.pdf
target: /srv/tts-game/TTS-Docs/static/thesis/mik0486
strip_components: 2
restart:
runs-on: ubuntu-latest
needs: build-latex
steps:
- name: Execute SSH Commands
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.SSH_HOST }}
username: root
key: ${{ secrets.SSH_PRIVATE_KEY }}
port: 22
script_stop: true
script: |
service tts-docs restart