-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy path.travis.yml
37 lines (31 loc) · 1.41 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
language: ruby
rvm: jruby
env:
- JAVA_OPTS="$(echo --add-opens java.base/sun.nio.ch=org.jruby.dist)"
cache:
paths:
- .bundle
before_install:
- sudo apt-get install graphviz
- mkdir -p output/cours output/tp output/images
- bundle config --local github.https true
- bundle --path=.bundle/gems --binstubs=.bundle/.bin
- cp common/course.css output/cours/style.css
- cp common/stylesheets/asciidoctor.css output/asciidoctor.css
script:
- bundle exec asciidoctor-revealjs -D output/cours -a revealjs_history=true -a revealjs_theme=white -a revealjs_slideNumber=true -a linkcss -a customcss=style.css -a revealjsdir=https://cdnjs.cloudflare.com/ajax/libs/reveal.js/3.8.0 cours/*.adoc
- bundle exec asciidoctor -D output README.adoc -a linkcss -a stylesheet=asciidoctor.css
- bundle exec asciidoctor -r asciidoctor-diagram -D output work.adoc -a linkcss -a stylesheet=asciidoctor.css
- bundle exec asciidoctor -r asciidoctor-diagram -D output/tp tp/*.adoc -a linkcss -a stylesheet=../asciidoctor.css
after_success:
- cd output ;
- mv README.html index.html
- cp -R ../cours/images cours
- cp -R ../tp/images tp
- cp -R ../assignments/eshop/images .
- git init
- git config user.name "${GH_USER_NAME}"
- git config user.email "{GH_USER_EMAIL}"
- git add .
- git commit -m "Deploy to GitHub Pages"
- git push --force --quiet "https://${GH_TOKEN}@${GH_REF}" master:gh-pages > /dev/null 2>&1