-
Notifications
You must be signed in to change notification settings - Fork 5
89 lines (80 loc) · 3.04 KB
/
main.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
84
85
86
87
88
89
name: Recompile styrdokument
# Controls when the action will run.
on:
# Triggers the workflow on pushing on the master branch
push:
branches: [ main ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
compile_latex:
runs-on: ubuntu-latest
steps:
# Checks-out the repository
- name: Checkout entire repository
uses: actions/checkout@v2
# Sets variables used later if files were changed
- name: Filter changed files
uses: dorny/[email protected]
id: filter
with:
filters: |
stadgar:
- 'stadgar/stadgar.tex'
reglemente:
- 'reglemente/*'
eko_reglemente:
- 'ekonomiskt_reglemente/ekonomiskt_reglemente.tex'
date-it-reglemente:
- 'date-it-styrdokument/date-it-reglemente.tex'
- name: Checkout dtek-class
uses: actions/checkout@v2
with:
repository: dtekcth/dTeX
path: './classes'
- run: 'cp -r ./classes/* ./stadgar'
if: steps.filter.outputs.stadgar == 'true'
- name: Kompilera stadgar
if: steps.filter.outputs.stadgar == 'true'
uses: vinay0410/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# Path of Tex File
tex_path: 'stadgar/stadgar.tex'
# String stating whether to push output PDF, PDF will only be pushed in case of "yes"
push: 'yes'
- run: 'cp -r ./classes/* ./reglemente'
if: steps.filter.outputs.reglemente == 'true'
- name: Kompilera reglemente
if: steps.filter.outputs.reglemente == 'true'
uses: vinay0410/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# Path of Tex File
tex_path: 'reglemente/reglemente.tex'
# String stating whether to push output PDF, PDF will only be pushed in case of "yes"
push: 'yes'
- run: 'cp -r ./classes/* ./ekonomiskt_reglemente'
if: steps.filter.outputs.eko_reglemente == 'true'
- name: Kompilera ekonomiskt reglemente
if: steps.filter.outputs.eko_reglemente == 'true'
uses: vinay0410/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# Path of Tex File
tex_path: 'ekonomiskt_reglemente/ekonomiskt_reglemente.tex'
# String stating whether to push output PDF, PDF will only be pushed in case of "yes"
push: 'yes'
- name: Kompilera DatE-ITs reglemente
if: steps.filter.outputs.date-it-regelemente == 'true'
uses: vinay0410/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# Path of Tex File
tex_path: 'date-it-styrdokument/date-it-reglemente.tex'
# String stating whether to push output PDF, PDF will only be pushed in case of "yes"
push: 'yes'