[latex3-commits] [git/LaTeX3-latex3-latex2e] develop: Correct logic (63dc0e35)
Joseph Wright
joseph.wright at morningstar2.co.uk
Thu Aug 1 12:45:53 CEST 2019
Repository : https://github.com/latex3/latex2e
On branch : develop
Link : https://github.com/latex3/latex2e/commit/63dc0e35437d593b9a9dc6e6d3b25a104e95530b
>---------------------------------------------------------------
commit 63dc0e35437d593b9a9dc6e6d3b25a104e95530b
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date: Thu Aug 1 11:38:44 2019 +0100
Correct logic
>---------------------------------------------------------------
63dc0e35437d593b9a9dc6e6d3b25a104e95530b
base/build.lua | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/base/build.lua b/base/build.lua
index 3ee58cdf..0db977a9 100644
--- a/base/build.lua
+++ b/base/build.lua
@@ -156,12 +156,15 @@ function update_tag(file,content,tagname,tagdate)
"Copyright (C) " .. oldyear .. "-" .. year)
end
end
- if not string.match(file,"%.md$") or not string.match(file,"ltvers.dtx") then
+ if not string.match(file,"%.md$") and not string.match(file,"ltvers.dtx") then
-- Stop here for files other than .md
return content
end
local iso = "%d%d%d%d%-%d%d%-%d%d"
- local tag, rev = string.match(tagname,"^(.*):([^:]*)$") or tagname,""
+ local tag, rev = string.match(tagname,"^(.*):([^:]*)$")
+ if not tag then
+ tag = tagname
+ end
local patch_level = ""
if master_branch then
if rev then
@@ -173,6 +176,8 @@ function update_tag(file,content,tagname,tagdate)
if rev then
tag = tag .. rev
patch_level = "-" .. rev
+ else
+ patch_level = "0"
end
end
if file == "README.md" then
@@ -181,7 +186,7 @@ function update_tag(file,content,tagname,tagdate)
"\nRelease " .. tag .. "\n")
elseif file == "ltvers.dtx" then
return string.gsub(content,
- "\\patch at level{%-?%d+}",
+ "\\patch at level{%-?%d}",
"\\patch at level{" .. patch_level .. "}")
end
return content
More information about the latex3-commits
mailing list