-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjustfile
More file actions
20 lines (19 loc) · 774 Bytes
/
justfile
File metadata and controls
20 lines (19 loc) · 774 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
module_name := "module-template"
zip_file := f"t-{{module_name}}.zip"
tex_module_file := f"t-{{module_name}}.mklx"
lua_module_file := f"t-{{module_name}}.lmt"
tex_doc_file := f"t-{{module_name}}.pdf"
temp_folder := "temp"
tex_folder := f"{{temp_folder}}/tex/context/third/{{module_name}}"
doc_folder := f"{{temp_folder}}/doc/context/third/{{module_name}}"
build:
-rm *.pdf "{{zip_file}}"
mkdir -p "{{tex_folder}}"
mkdir -p "{{doc_folder}}"
context "{{tex_module_file}}"
mtxrun --script context --purgeall
cp "LICENSE" "VERSION" "CHANGELOG.md" "README.md" "{{temp_folder}}"
cp "{{tex_module_file}}" "{{lua_module_file}}" "{{tex_folder}}"
mv "{{tex_doc_file}}" "{{doc_folder}}"
cd "{{temp_folder}}" && zip -r "../{{zip_file}}" .
rm -rf "{{temp_folder}}"