chore: if tagname is nil, use old_version instead

This commit is contained in:
Johan Larsson 2024-01-17 19:46:27 +01:00
parent a8c3c585e2
commit 6f88c49765
1 changed files with 6 additions and 1 deletions

View File

@ -15,11 +15,16 @@ function update_tag(file, content, tagname, tagdate)
return content:gsub(
pattern,
function(package_name, old_date, old_version, description)
-- if tagdate is nil, use old_date
if tagname == nil then
tagname = old_version
end
return string.format(
"\\ProvidesPackage{%s}[%s v%s %s]",
package_name,
tagdate,
old_version,
tagname,
description
)
end