-
Notifications
You must be signed in to change notification settings - Fork 109
/
build.lua
82 lines (73 loc) · 2.8 KB
/
build.lua
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
-- Identify the bundle and module
module = "pgf"
-- TDS-based installation
installfiles = {}
sourcefiles = {}
unpackfiles = {}
tdsdirs = {tex = "tex"}
-- For the manual
docfiledir = "./doc/generic/pgf"
docfiles =
{
"RELEASE_NOTES.md", "description.html", -- Part of the release script
"color.cfg", "pgfmanual.cfg", "images", "plots", "*.tex" -- Build the manual
}
tdsroot = "generic"
typesetfiles = {"pgfmanual.tex"}
typesetexe = "lualatex"
flatten = false
-- Set up to allow testing dvips, etc.
specialformats = specialformats or {}
specialformats["latex"] = specialformats["latex"] or
{
latexdvips = {binary = "latex", format = ""},
latexdvisvgm =
{
binary = "lualatex",
format = "",
options = "--output-format=dvi",
tokens = "\\def\\pgfsysdriver{pgfsys-dvisvgm.def}"
}
}
checkengines = {"pdftex", "latexdvips", "latexdvisvgm", "luatex", "xetex"}
-- Use multiple sets of tests
checkconfigs = { "build", "config-gd" }
-- For release
ctanzip = "pgf.ctan.flatdir"
packtdszip = true
-- if ctanupload is nil or false, only validation is attempted
if options["dry-run"] then
ctanupload = false
end
-- CTAN upload
uploadconfig = {
announcement_file = "RELEASE_NOTES.md",
author = "Christian Feuersänger;Henri Menke;The PGF/TikZ Team;Till Tantau",
bugs = "https://github.com/pgf-tikz/pgf/issues",
ctanPath = "/graphics/pgf/base",
description = [[<p>PGF is a macro package for creating graphics. It is platform- and format-independent and works together with the most important TeX backend drivers, including pdfTeX and dvips. It comes with a user-friendly syntax layer called TikZ.<br></p><p>Its usage is similar to <a data-cke-saved-href="/pkg/pstricks-base" href="/pkg/pstricks-base">pstricks</a> and the standard picture environment. PGF works with plain (pdf-)TeX, (pdf-)LaTeX, and ConTeXt. Unlike <a data-cke-saved-href="/pkg/pstricks-base" href="/pkg/pstricks-base">pstricks</a>, it can produce either PostScript or PDF output.<br></p>]],
email = "pgf-tikz@tug.org",
license = { "fdl", "gpl2", "lppl1.3c" },
note_file = "CTAN_NOTES.md",
pkg = "pgf",
repository = "https://github.com/pgf-tikz/pgf",
summary = "Create PostScript and PDF graphics in TeX",
support = "https://tug.org/mailman/listinfo/pgf-tikz",
update = true,
uploader = "github-actions",
-- version has to be passed on the command line
}
function tag_hook(tagname, tagdate)
local revision = options["--revision"] or tagname
local revisiondate = options["--revision-date"] or tagdate
local revisionfiletext = [[
\def\pgfrevision{%s}
\def\pgfversion{%s}
\def\pgfrevisiondate{%s}
\def\pgfversiondate{%s}
]]
local file = io.open("tex/generic/pgf/pgf.revision.tex", "w")
file:write(string.format(revisionfiletext, revision, tagname, revisiondate, tagdate))
file:close()
return 0
end