-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.lua
More file actions
63 lines (59 loc) · 2.15 KB
/
build.lua
File metadata and controls
63 lines (59 loc) · 2.15 KB
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
-- SPDX-FileCopyrightText: Copyright (c) 2021-2026 Yegor Bugayenko
-- SPDX-License-Identifier: MIT
module = "eolang"
ctanupload = true
typesetopts = "-interaction=batchmode -shell-escape -halt-on-error"
checkopts = "-interaction=batchmode -shell-escape -halt-on-error"
sourcefiles = {"*.dtx", "*.ins", "*-????-??-??.sty", "eolang.pl"}
exefiles = {"eolang.pl"}
checkengines = {"pdftex"}
-- checkengines = {"pdftex", "luatex", "xetex"}
tagfiles = {"build.lua", "eolang.dtx"}
docfiles = {"cactus.pdf", "eolang.bib"}
cleanfiles = {"build", "_docshots", "*.pl.eolang", "*.run.xml", "*.log", "*.bcf", "*.glo", "*.fls", "*.idx", "*.out", "*.fdb_latexmk", "*.aux", "*.sty", "*.zip", "eolang.pdf"}
checkfiles = {"eolang.pl"}
scriptfiles = {"eolang.pl"}
scriptmanfiles = {"eolang.1"}
tagfiles = {"eolang.dtx", "eolang.pl", "build.lua", "eolang.1"}
typesetruns = 3
checkruns = 1
uploadconfig = {
pkg = "eolang",
version = "0.0.0 0000-00-00",
author = "Yegor Bugayenko",
uploader = "Yegor Bugayenko",
email = "yegor256@gmail.com",
note = "Bug fixes",
announcement = "",
ctanPath = "/macros/latex/contrib/eolang",
bugtracker = "https://github.com/objectionary/eolang.sty/issues",
home = "",
description = "This package helps you format expressions of 𝜑-calculus and draw SODG graphs for EO programming language",
development = "",
license = "mit",
summary = "Formulas and graphs for EO programming language",
repository = "https://github.com/objectionary/eolang.sty",
support = "",
topic = {"program-doc", "diagram"}
}
function update_tag(file, content, tagname, tagdate)
return string.gsub(
string.gsub(content, "0%.0%.0", tagname),
"0000-00-00", os.date("%Y-%m-%d")
)
end
-- Run all Perl test scripts before packaging
function ctan_pre_action()
print("Running Perl test scripts from tests/ directory...")
local handle = io.popen("ls -1 tests/*.pl")
local result = handle:read("*a")
handle:close()
for script in string.gmatch(result, "([^\n]+)") do
print("Running " .. script)
os.execute("perl " .. script)
if not os.execute("perl " .. script) then
error("Test script " .. script .. " failed!")
end
end
return true
end