From 8dbfb3ceca3b858b690eb65d8802ef3367add902 Mon Sep 17 00:00:00 2001 From: Augusto Goulart <26435937+oAGoulart@users.noreply.github.com> Date: Sat, 28 Mar 2020 17:41:03 +0100 Subject: [PATCH] Fix windows release directory renaming. Fixed bug caused by the use of `%` on replacement string when calling `string.gsub` (lua >= 5.2). According to [lua-users](http://lua-users.org/wiki/LuaFiveTwo): > ### string.gsub repl > > string.gsub > [[6](http://www.lua.org/manual/5.2/manual.html#pdf-string.gsub)] now > raises an error if the replacement string contains a '%' followed by > a character other than the permitted '%' or digit. In short, the replacement string does not require escaping of *magic characters*. --- src/scripts/windows.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/scripts/windows.lua b/src/scripts/windows.lua index 1044258..8319a39 100644 --- a/src/scripts/windows.lua +++ b/src/scripts/windows.lua @@ -74,7 +74,7 @@ local function release(script, project, arch) if stat then ar:rename(i, stat.name:gsub( "^"..utils.lua.escape_string_regex(dir), - utils.lua.escape_string_regex(project.title).."-win"..arch.."/")) + project.title.."-win"..arch.."/")) end end