add ci and some fixes
This commit is contained in:
parent
c35ed6dbc1
commit
b0d831fe1a
54
.drone.yml
Normal file
54
.drone.yml
Normal file
|
@ -0,0 +1,54 @@
|
|||
pipeline:
|
||||
build-latex:
|
||||
image: jess/texlive
|
||||
commands:
|
||||
- apt-get update
|
||||
- apt-get install -y --no-install-recommends wget rubber make inkscape
|
||||
- ./compile.sh latex
|
||||
|
||||
build-libreoffice:
|
||||
image: jess/libreoffice
|
||||
commands:
|
||||
- wget -P /usr/share/fonts -c -q
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraMono-Bold.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraMono-Medium.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraMono-Regular.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Bold.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-BoldItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Book.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-BookItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Eight.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-EightItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-ExtraBold.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-ExtraBoldItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-ExtraLight.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-ExtraLightItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Four.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-FourItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Hair.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-HairItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Heavy.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-HeavyItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Light.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Italic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-LightItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Medium.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-MediumItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Regular.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-SemiBold.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-SemiBoldItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Thin.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-ThinItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Two.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-TwoItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-Ultra.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-UltraItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-UltraLightItalic.ttf
|
||||
https://cdn.jsdelivr.net/npm/mozilla-fira-pack/Fira/ttf/FiraSans-UltraLight.ttf
|
||||
- ./compile.sh libreoffice
|
||||
|
||||
build-revealjs:
|
||||
image: node:alpine
|
||||
commands:
|
||||
- apk add --no-cache make
|
||||
- ./compile.sh revealjs
|
4
.gitmodules
vendored
4
.gitmodules
vendored
|
@ -1,5 +1,5 @@
|
|||
[submodule "latex/mtheme"]
|
||||
path = latex/mtheme
|
||||
[submodule "mtheme"]
|
||||
path = mtheme
|
||||
url = https://github.com/matze/mtheme
|
||||
[submodule "revealjs/amnesty/amnesty-dp-2016"]
|
||||
path = revealjs/amnesty/amnesty-dp-2016
|
||||
|
|
5
Makefile
5
Makefile
|
@ -1,3 +1,6 @@
|
|||
.PHONY: default
|
||||
default:
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
find latex \
|
||||
|
@ -12,7 +15,7 @@ clean:
|
|||
-o -iname "*.eps" \
|
||||
\) \
|
||||
-delete
|
||||
find . -iname "*.pdf" -type f -delete
|
||||
find latex revealjs -iname "*.pdf" -type f -delete
|
||||
rm -rf latex/fonts revealjs/node_modules
|
||||
|
||||
latex/fonts:
|
||||
|
|
41
compile.sh
41
compile.sh
|
@ -1,39 +1,32 @@
|
|||
#!/bin/bash
|
||||
set -e
|
||||
set -x
|
||||
|
||||
##
|
||||
# Build LaTeX documents
|
||||
##
|
||||
|
||||
#!/bin/sh
|
||||
case "$1" in
|
||||
"latex")
|
||||
make fonts
|
||||
|
||||
for presi in latex/*;do
|
||||
# [ "$presi" == "latex/mtheme" ] && break
|
||||
# [ "$presi" == "latex/fonts" ] && break
|
||||
|
||||
for file in $presi/*.svg;do
|
||||
[ -e "$file" ] && make "${file%.svg}".eps
|
||||
done
|
||||
|
||||
[ -e "$presi/index.tex" ] && make "$presi/index.pdf"
|
||||
done
|
||||
|
||||
true
|
||||
;;
|
||||
"libreoffice")
|
||||
for presi in latex/* revealjs/*;do
|
||||
[ -e "$presi/handout.odt" ] && make "$presi/handout.pdf"
|
||||
done
|
||||
|
||||
##
|
||||
# install nodejs modules
|
||||
##
|
||||
|
||||
;;
|
||||
"revealjs")
|
||||
make revealjs/node_modules
|
||||
|
||||
##
|
||||
# Build PDF for revealjs
|
||||
##
|
||||
|
||||
for presi in revealjs/*;do
|
||||
# [ "$presi" == "revealjs/node_modules" ] && break
|
||||
|
||||
[ -e "$presi/index.html" ] && make "$presi/index.pdf"
|
||||
|
||||
[ -e $presi/handout.odt ] && make "$presi/handout.pdf"
|
||||
done
|
||||
;;
|
||||
*)
|
||||
echo "USAGE: $0 [MODE]"
|
||||
echo "modes: latex libreoffice revealjs"
|
||||
;;
|
||||
esac
|
||||
|
|
Reference in a new issue