add commit in draft

This commit is contained in:
Jean-Marie Mineau 2025-06-25 11:52:01 +02:00
parent 3f3eb37339
commit 25342bd4b3
Signed by: histausse
GPG key ID: B66AEEDA9B645AD2
4 changed files with 19 additions and 3 deletions

View file

@ -36,7 +36,12 @@
) = {
assert-etablissements(university)
if draft {
if draft {
[== DRAFT - #title-en]
// if typst was called with `--input commit=$(git rev-parse --short HEAD)`, add the current commit:
if "commit" in sys.inputs {
[Current version: commit #sys.inputs.commit \ \ ]
}
todos()
} else {
show-todos.update(false)
@ -90,7 +95,7 @@
// display last level-2 heading (current page included)
let header-content = hydra(2, use-last: true,
display: (_, it) => {
if it.numbering == none [_ #it.body _ ]
if it.numbering == none [_ #it.body _]
else {
let nb = counter(heading).at(it.location())
let nb-fmt = numbering(