-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.drone.yml
62 lines (53 loc) · 1.53 KB
/
.drone.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
kind: pipeline
name: deploy
clone:
depth: 50
steps:
- name: submodules
image: docker:git
commands:
- git submodule update --init --recursive --remote
- name: hotfix
image: anoff/hugo-asciidoctor
commands:
- cp -R theme_fixes/** themes/bilberry-hugo-theme
- name: tag-cv
image: alpine/git
commands:
- cd static/cv
- git rev-list --abbrev-commit -1 HEAD cv-anoff.tex > .COMMIT_SHA
- name: build-cv
image: thomasweise/texlive
commands:
- cd static/cv
- export COMMIT_SHA=$(cat .COMMIT_SHA)
- sed -i.bak "s/\({git:\)[[:alnum:]]*\(}\)/\1"$COMMIT_SHA"\2/" cv-anoff.tex
- lualatex.sh cv-anoff.tex || echo "Ignoring original.pdf error"
- mv cv-anoff.tex.bak cv-anoff.tex
- name: build-cv-print
image: thomasweise/texlive
commands:
- cd static/cv
- cp cv-anoff.tex cv-anoff-print.tex
- export COMMIT_SHA=$(cat .COMMIT_SHA)
- sed -i.bak "s/\({git:\)[[:alnum:]]*\(}\)/\1"$COMMIT_SHA"\2/" cv-anoff-print.tex
- sed -i.bak "s/\([[:alnum:]]*documentclass\[\)\([[:alnum:]]*\)\(\]{friggeri-cv}.[[:alnum:]]*\)/\1print\2\3/" cv-anoff-print.tex
- lualatex.sh cv-anoff-print.tex || echo "Ignoring original.pdf error"
- rm cv-anoff-print.tex
- name: build-page
image: anoff/hugo-asciidoctor
commands:
- hugo --gc --minify -d _site --baseURL https://anoff.io
- touch _site/.nojekyll
- name: publish
image: plugins/gh-pages
settings:
username:
from_secret: github_username
password:
from_secret: github_token
pages_directory: _site
target_branch: master
when:
branch:
- source