diff options
author | Ignacio Burgueño <iburgueno@gmail.com> | 2015-05-05 08:55:03 -0300 |
---|---|---|
committer | Ignacio Burgueño <iburgueno@gmail.com> | 2015-05-05 08:55:03 -0300 |
commit | 70c75776c2d8771c6d66dd4d5facbb4e55a1148e (patch) | |
tree | b0a5f06cf156c48e6279ba4e7e12d7a2a5833928 /src | |
parent | 0d071fa685e41864986c9537efe0bca80d69c280 (diff) | |
parent | 11b8b48978118e5cc4e30f63274c63245cecb6ef (diff) | |
download | luarocks-70c75776c2d8771c6d66dd4d5facbb4e55a1148e.tar.gz luarocks-70c75776c2d8771c6d66dd4d5facbb4e55a1148e.tar.bz2 luarocks-70c75776c2d8771c6d66dd4d5facbb4e55a1148e.zip |
Merge pull request #366 from Tieske/windows_exitcode
Provide proper exitcode on windows
Diffstat (limited to 'src')
-rw-r--r-- | src/luarocks/fs/win32.lua | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/luarocks/fs/win32.lua b/src/luarocks/fs/win32.lua index 12d86d1d..32766e53 100644 --- a/src/luarocks/fs/win32.lua +++ b/src/luarocks/fs/win32.lua | |||
@@ -125,6 +125,7 @@ function win32.wrap_script(file, dest, name, version) | |||
125 | local ppaths = "package.path="..util.LQ(lpath..";").."..package.path; package.cpath="..util.LQ(lcpath..";").."..package.cpath" | 125 | local ppaths = "package.path="..util.LQ(lpath..";").."..package.path; package.cpath="..util.LQ(lcpath..";").."..package.cpath" |
126 | local addctx = "local k,l,_=pcall(require,"..util.LQ("luarocks.loader")..") _=k and l.add_context("..util.LQ(name)..","..util.LQ(version)..")" | 126 | local addctx = "local k,l,_=pcall(require,"..util.LQ("luarocks.loader")..") _=k and l.add_context("..util.LQ(name)..","..util.LQ(version)..")" |
127 | wrapper:write(fs.Qb(lua)..' -e '..fs.Qb(ppaths)..' -e '..fs.Qb(addctx)..' '..fs.Qb(file)..' %*\n') | 127 | wrapper:write(fs.Qb(lua)..' -e '..fs.Qb(ppaths)..' -e '..fs.Qb(addctx)..' '..fs.Qb(file)..' %*\n') |
128 | wrapper:write("exit /b %ERRORLEVEL%\n") | ||
128 | wrapper:close() | 129 | wrapper:close() |
129 | return true | 130 | return true |
130 | end | 131 | end |