forked from UCL/rsd-cppcourse
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSConstruct
26 lines (23 loc) · 1.03 KB
/
SConstruct
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
import os
pandoc_latex=Builder(action='pandoc --template=report -V documentclass=scrartcl -V'+
' links-as-notes -V linkcolor="uclmidgreen" --number-sections $SOURCES -o $TARGET')
env=Environment()
env.Append(BUILDERS={'PandocLatex':pandoc_latex})
intro=Glob("introduction/*.md")
sessions={}
for session in range(1,4):
sessions["session{session}".format(session=session)]=Glob("session{session}/*.md".format(session=session))
appendices=Glob("appendices/*.md")
sessions["intro"]=intro
sessions["appendices"]=appendices
session_names=["intro", "session1", "session2","session3","appendices"]
notes=env.PandocLatex('CPP.pdf',[sessions[name] for name in session_names])
Depends(notes,'report.latex')
pandoc_slides=Builder(action='pandoc -t revealjs -s -V theme=beige'+
' --css=beige.css'+
' --css=slidetheme.css'+
' --mathjax '+
' -V revealjs-url=http://lab.hakim.se/reveal-js/'+
' $SOURCES -o $TARGET')
env.Append(BUILDERS={'PandocSlides':pandoc_slides})
slides=env.PandocSlides("reveal/index.html",[sessions[name] for name in session_names])