Skip to content

Commit 4794ccf

Browse files
committed
Add github automation
Add some automation so that the files are built. Signed-off-by: Simon Glass <[email protected]>
1 parent 00efa73 commit 4794ccf

File tree

1 file changed

+60
-0
lines changed

1 file changed

+60
-0
lines changed

.github/workflows/ci.yml

+60
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: Github Action CI
2+
3+
on:
4+
push:
5+
branches:
6+
- '**'
7+
tags:
8+
- 'v*'
9+
pull_request:
10+
branches:
11+
master
12+
13+
jobs:
14+
build:
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
with:
20+
fetch-depth: 0
21+
22+
- name: install
23+
run: |
24+
sudo apt-get update
25+
sudo apt-get install latexmk libalgorithm-diff-perl texlive texlive-latex-extra texlive-humanities graphviz
26+
pip3 install --user mako
27+
pip3 install --user typing
28+
pip3 install --user Sphinx
29+
pip3 install --user codespell
30+
31+
- name: build pdf
32+
run: |
33+
make latexpdf
34+
git fetch --tags --force # Needed to make git-describe work
35+
mv build/latex/fit-specification.pdf build/latex/fit-specification-$(git describe).pdf
36+
- name: build html
37+
run: make html
38+
- name: build singlehtml
39+
run: make singlehtml
40+
41+
- name: upload
42+
uses: actions/upload-artifact@v2
43+
with:
44+
name: artifacts
45+
path: |
46+
build/latex/fit-specification-*.pdf
47+
48+
- name: deploy
49+
uses: peaceiris/actions-gh-pages@v3
50+
with:
51+
github_token: ${{ secrets.GITHUB_TOKEN }}
52+
publish_dir: ./build/singlehtml
53+
54+
- name: release
55+
uses: softprops/action-gh-release@v1
56+
if: startsWith(github.ref, 'refs/tags/')
57+
with:
58+
files: build/latex/fit-specification-*.pdf
59+
env:
60+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)