-
Notifications
You must be signed in to change notification settings - Fork 4
/
.travis.yml
65 lines (60 loc) · 2.38 KB
/
.travis.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
language: generic
dist: focal
cache: apt
env:
global:
- PANDOC_VERSION=2.18
- PANDOC_CROSSREF_VERSION=0.3.13.0
addons:
apt:
packages:
- fonts-croscore
- fonts-crosextra-carlito
- fonts-linuxlibertine
- fonts-inconsolata
- fonts-texgyre
- lmodern
- make
- tex-gyre
- texlive-fonts-extra
- texlive-fonts-recommended
- texlive-lang-french
- texlive-latex-extra
- texlive-science
- texlive-xetex
install:
- wget https://github.com/jgm/pandoc/releases/download/${PANDOC_VERSION}/pandoc-${PANDOC_VERSION}-1-amd64.deb -O pandoc.deb
- sudo dpkg -i pandoc.deb
- wget https://github.com/lierdakil/pandoc-crossref/releases/download/v${PANDOC_CROSSREF_VERSION}/pandoc-crossref-Linux.tar.xz -O pandoc-crossref.tar.xz
- tar xf pandoc-crossref.tar.xz
- sudo mv pandoc-crossref /usr/local/bin
jobs:
include:
- stage: build
script: make all
- stage: deploy
if: branch = main
script: |
(
make all
mkdir build
cp *.pdf rapport.md build
cd build
cat <<EOF > index.html
<!DOCTYPE html><meta charset=utf-8><title>Rapport Technique</title>
<style>body { font-family: sans-serif; color: #222; line-height: 1.2 }</style>
<h1>Télécharger le rapport technique (<a href="rapport.md">source Markdown</a>)</h1>
<p>Styles</p><ul>
<li><a href="rapport.pdf">Koma + Linux Libertine</a>
<li><a href="rapport-cros.pdf">Koma + Chrome OS</a>
<li><a href="rapport-gyre.pdf">Simple + TeX Gyre</a>
</ul><a href="https://github.com/HE-Arc/rapport-technique"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://camo.githubusercontent.com/a6677b08c955af8400f44c6298f40e7d19cc5b2d/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f677261795f3664366436642e706e67" alt="Fork me on GitHub" data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png"></a>
EOF
git init
git config user.name "TravisCI"
git config user.email "[email protected]"
touch .nojekyll
git add .
git commit -m "Deployed to github pages"
git push -f -q "https://${GH_TOKEN}@github.com/${TRAVIS_REPO_SLUG}" master:gh-pages
)