Skip to content

Commit 2f661d3

Browse files
committed
fix template and automate
1 parent ed30f76 commit 2f661d3

File tree

3 files changed

+24
-15
lines changed

3 files changed

+24
-15
lines changed

.template/metadata.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# document class
21
---
32
fontsize: 12pt
43
author: "The Learned Contributors to OpenLex"

.travis.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,16 @@ install:
33
- sudo apt-get install -y pandoc texlive-full texlive-xetex
44
- chmod u+x .ci/update_build.sh
55

6+
env:
7+
- BUILD_TIME=$(TZ=Asia/Hong_Kong date '+%a %d %b %Y %T %Z')
8+
- ADMIN=`ls openlex-admin`
9+
- CONS=`ls openlex-cons`
10+
- CONTRACT=`ls openlex-contract`
11+
- CRIM=`ls openlex-crim`
12+
- EQUITY=`ls openlex-equity`
13+
- LAND=`ls openlex-land`
14+
- TORT=`ls openlex-tort`
15+
616
before_script:
717
- BUILD_TIME=$(TZ=Asia/Hong_Kong date '+%a %d %b %Y %T %Z')
818

Makefile

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,23 @@ all: admin cons contract crim equity land tort
22

33
travis: contract
44

5-
admin: .template/template.tex openlex-admin/openlex-admin.md .template/metadata.yaml
6-
pandoc -N --template=.template/template.tex --variable title="Administrative Law" openlex-admin/openlex-admin.md .template/metadata.yaml --latex-engine=xelatex --toc -o openlex-admin.pdf
5+
admin: .template/template.tex .template/metadata.yaml
6+
pandoc -N --template=.template/template.tex --variable title="Administrative Law" .template/metadata.yaml $$ADMIN --latex-engine=xelatex --toc -o openlex-admin.pdf
77

8-
cons: .template/template.tex openlex-cons/openlex-cons.md .template/metadata.yaml
9-
pandoc -N --template=.template/template.tex --variable title="Constitutional Law" openlex-cons/openlex-cons.md .template/metadata.yaml --latex-engine=xelatex --toc -o openlex-cons.pdf
8+
cons: .template/template.tex .template/metadata.yaml
9+
pandoc -N --template=.template/template.tex --variable title="Constitutional Law" .template/metadata.yaml $$CONS --latex-engine=xelatex --toc -o openlex-cons.pdf
1010

11-
contract: .template/template.tex openlex-contract/openlex-contract.md .template/metadata.yaml
12-
pandoc -N --template=.template/template.tex --variable title="Law of Contract" openlex-contract/openlex-contract.md .template/metadata.yaml --latex-engine=xelatex --toc -o openlex-contract.pdf
11+
contract: .template/template.tex .template/metadata.yaml
12+
pandoc -N --template=.template/template.tex --variable title="Law of Contract" .template/metadata.yaml $$CONTRACT --latex-engine=xelatex --toc -o openlex-contract.pdf
1313

14-
crim: .template/template.tex openlex-crim/openlex-crim.md .template/metadata.yaml
15-
pandoc -N --template=.template/template.tex --variable title="Criminal Law" openlex-crim/openlex-crim.md .template/metadata.yaml --latex-engine=xelatex --toc -o openlex-crim.pdf
14+
crim: .template/template.tex .template/metadata.yaml
15+
pandoc -N --template=.template/template.tex --variable title="Criminal Law" .template/metadata.yaml $$CRIM --latex-engine=xelatex --toc -o openlex-crim.pdf
1616

17-
equity: .template/template.tex openlex-equity/openlex-equity.md .template/metadata.yaml
18-
pandoc -N --template=.template/template.tex --variable title="Equity and Trust" openlex-equity/openlex-equity.md .template/metadata.yaml --latex-engine=xelatex --toc -o openlex-equity.pdf
17+
equity: .template/template.tex .template/metadata.yaml
18+
pandoc -N --template=.template/template.tex --variable title="Equity and Trust" .template/metadata.yaml $$EQUITY --latex-engine=xelatex --toc -o openlex-equity.pdf
1919

20-
land: .template/template.tex openlex-land/openlex-land.md .template/metadata.yaml
21-
pandoc -N --template=.template/template.tex --variable title="Land Law" openlex-land/openlex-land.md .template/metadata.yaml --latex-engine=xelatex --toc -o openlex-land.pdf
20+
land: .template/template.tex .template/metadata.yaml
21+
pandoc -N --template=.template/template.tex --variable title="Land Law" template/metadata.yaml $$LAND .--latex-engine=xelatex --toc -o openlex-land.pdf
2222

23-
tort: .template/template.tex openlex-tort/openlex-tort.md .template/metadata.yaml
24-
pandoc -N --template=.template/template.tex --variable title="Tort Law" openlex-tort/openlex-tort.md .template/metadata.yaml --latex-engine=xelatex --toc -o openlex-tort.pdf
23+
tort: .template/template.tex .template/metadata.yaml
24+
pandoc -N --template=.template/template.tex --variable title="Tort Law" .template/metadata.yaml $$TORT --latex-engine=xelatex --toc -o openlex-tort.pdf

0 commit comments

Comments
 (0)