diff options
author | Hisham Muhammad <hisham@gobolinux.org> | 2010-10-15 14:09:30 -0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2010-10-15 14:09:30 -0300 |
commit | ffcd0f2e953e242af5de2ee4b9d52768891ed98b (patch) | |
tree | dae85382f01475e86069abef64ca550c7146f607 | |
parent | d0d848ad3bd364993e4c8f933c14075f4c91b126 (diff) | |
download | luarocks-ffcd0f2e953e242af5de2ee4b9d52768891ed98b.tar.gz luarocks-ffcd0f2e953e242af5de2ee4b9d52768891ed98b.tar.bz2 luarocks-ffcd0f2e953e242af5de2ee4b9d52768891ed98b.zip |
Display the name of file created by 'pack'.
(Also fixes the return of the run() command.)
-rw-r--r-- | src/luarocks/pack.lua | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/luarocks/pack.lua b/src/luarocks/pack.lua index e2b59a6f..5546a649 100644 --- a/src/luarocks/pack.lua +++ b/src/luarocks/pack.lua | |||
@@ -163,9 +163,16 @@ function run(...) | |||
163 | return nil, "Argument missing, see help." | 163 | return nil, "Argument missing, see help." |
164 | end | 164 | end |
165 | 165 | ||
166 | local file, err | ||
166 | if arg:match(".*%.rockspec") then | 167 | if arg:match(".*%.rockspec") then |
167 | return pack_source_rock(arg) | 168 | file, err = pack_source_rock(arg) |
168 | else | 169 | else |
169 | return pack_binary_rock(arg, version) | 170 | file, err = pack_binary_rock(arg, version) |
171 | end | ||
172 | if err then | ||
173 | return nil, err | ||
174 | else | ||
175 | print("Packed: "..file) | ||
176 | return true | ||
170 | end | 177 | end |
171 | end | 178 | end |