-
Notifications
You must be signed in to change notification settings - Fork 33
133 lines (121 loc) · 3.53 KB
/
check.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
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
name: check
on:
push:
branches:
- main
pull_request:
schedule:
- cron: '1 2 5 * *'
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
cache:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
with:
show-progress: ''
- name: Install TeX Live
uses: zauguin/install-texlive@v3
with:
package_file: Texlivefile
build:
needs: [cache]
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
engine: [pdflatex, lualatex]
steps:
- name: Check out code
uses: actions/checkout@v4
with:
show-progress: ''
- name: Install TeX Live
uses: zauguin/install-texlive@v3
with:
package_file: Texlivefile
- name: Generate lni.cls, *.tex, ...
run: |
pdflatex lni.ins
pdflatex lni.dtx
pdflatex lni.dtx
pdflatex lni.dtx
- name: Check for modifications
run: |
git update-index --refresh
if ! git diff-index --quiet HEAD --; then
echo "Worktree is not clean."
git diff-index --name-status HEAD
exit 1
fi
- name: Generate mybibfile.bib
run: touch mybibfile.bib
# lni-author-template
- run: ${{ matrix.engine }} lni-author-template
- run: texlogsieve lni-author-template.log
# lni-paper-example-de
- run: ${{ matrix.engine }} lni-paper-example-de
- run: biber lni-paper-example-de
- run: ${{ matrix.engine }} lni-paper-example-de
- run: ${{ matrix.engine }} lni-paper-example-de
- run: texlogsieve lni-paper-example-de.log
- name: Upload build result
uses: actions/upload-artifact@v4
with:
name: PDFs-${{ matrix.engine }}
path: |
lni-author-template.pdf
lni-paper-example*.pdf
*.log
- name: Prepare GH pages content
if: github.ref == 'refs/heads/main' && matrix.engine == 'lualatex'
run: |
set -e
mkdir /tmp/gh-pages
cp README.md /tmp/gh-pages/index.md
cp *.pdf /tmp/gh-pages
- name: Deploy to GH pages
uses: peaceiris/actions-gh-pages@v4
if: github.ref == 'refs/heads/main' && matrix.engine == 'lualatex'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: /tmp/gh-pages
- name: Install dependencies for ctanify
if: matrix.engine != 'lualatex'
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: libfile-copy-recursive-perl
version: 1.0
- name: Prepare for CTAN
if: matrix.engine != 'lualatex'
run: ./prepare_for_CTAN
- name: Upload CTAN build
if: matrix.engine != 'lualatex'
uses: actions/upload-artifact@v4
with:
name: CTAN-${{ matrix.engine }}
path: '*.tar.gz'
changelog:
name: CHANGELOG.md
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
with:
show-progress: ''
- uses: jbangdev/jbang-action@v0.115.0
with:
script: com.github.nbbrd.heylogs:heylogs-cli:0.7.2:bin
scriptargs: "check CHANGELOG.md"
keepalive:
name: Keepalive
runs-on: ubuntu-latest
permissions:
actions: write
steps:
- uses: actions/checkout@v4
- uses: gautamkrishnar/keepalive-workflow@v2