From 8511d6d6ebfa346be0e39ff9e032655921d608eb Mon Sep 17 00:00:00 2001 From: LogCreative Date: Sun, 22 Oct 2023 23:36:27 +0800 Subject: [PATCH] docs: build info --- build.lua | 31 ++++++++++++++++++------------- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/build.lua b/build.lua index 08e627c..0d2c7b7 100644 --- a/build.lua +++ b/build.lua @@ -1,5 +1,10 @@ #!/usr/bin/env texlua +--[[ + In short, to build the project: + l3build ctan +]] + module = "presenter" docfiledir = "texmf/doc/latex/" .. module @@ -7,19 +12,31 @@ typesetfiles = {"presenter-doc.tex"} sourcefiledir = "texmf/source/latex/" .. module +-- l3build check +-- Checking will copy the unpack files to the final directory. testfiledir = "testfiles" testsuppdir = testfiledir .. "/support" +installfiles = {"*.sty", "*.cls"} +extraunpackdir = "texmf/tex/latex/" .. module +function checkinit_hook() + for _,src in pairs(installfiles) do + cp(src, unpackdir, extraunpackdir) + end + return 0 +end +-- l3build doc +-- prepare the test pdf in the doc (should be done after 'l3build check') maindir = "." builddir = maindir .. "/build" testdir = builddir .. "/test" typesetdir = builddir .. "/doc" --- prepare the test pdf in the doc function docinit_hook() cp("*.pdf", testdir, typesetdir) return 0 end +-- l3build tag x.x.x -- Simple tagging, copyright information needs manual update. tagfiles = {"*.dtx","presenter-doc.tex"} function update_tag(file, content, tagname, tagdate) @@ -34,15 +51,3 @@ function update_tag(file, content, tagname, tagdate) end return content end - -installfiles = {"*.sty", "*.cls"} -extraunpackdir = "texmf/tex/latex/" .. module - --- Checking will copy the unpack files to the final directory. -function checkinit_hook() - for _,src in pairs(installfiles) do - cp(src, unpackdir, extraunpackdir) - end - - return 0 -end