diff options
| author | Peter Melnichenko <mpeterval@gmail.com> | 2016-05-10 15:48:33 +0300 |
|---|---|---|
| committer | Peter Melnichenko <mpeterval@gmail.com> | 2016-05-10 16:46:37 +0300 |
| commit | 6beb0ef346cc7fd097a4736a7b27755a84165287 (patch) | |
| tree | fede234a0ff60b95b05896fb3868b38134ae3e61 /src | |
| parent | a8fe9e376ee4517486513b47e7be143311c96e06 (diff) | |
| download | luarocks-6beb0ef346cc7fd097a4736a7b27755a84165287.tar.gz luarocks-6beb0ef346cc7fd097a4736a7b27755a84165287.tar.bz2 luarocks-6beb0ef346cc7fd097a4736a7b27755a84165287.zip | |
Shorten logging for `luarocks install`
Instead of mentioning URL twice in
Installing URL...
Using URL... switching to 'build' mode
simply print
Installing URL
and don't print URL at all when it's the argument to `luarocks install`
(it's a bit redundant), only when it's a result of a search.
Diffstat (limited to 'src')
| -rw-r--r-- | src/luarocks/deps.lua | 1 | ||||
| -rw-r--r-- | src/luarocks/install.lua | 3 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/luarocks/deps.lua b/src/luarocks/deps.lua index 812e6d18..ac294f54 100644 --- a/src/luarocks/deps.lua +++ b/src/luarocks/deps.lua | |||
| @@ -488,6 +488,7 @@ function deps.fulfill_dependencies(rockspec, deps_mode) | |||
| 488 | if not url then | 488 | if not url then |
| 489 | return nil, "Could not satisfy dependency "..deps.show_dep(dep)..": "..err | 489 | return nil, "Could not satisfy dependency "..deps.show_dep(dep)..": "..err |
| 490 | end | 490 | end |
| 491 | util.printout("Installing "..url) | ||
| 491 | local ok, err, errcode = install.run(url, deps.deps_mode_to_flag(deps_mode)) | 492 | local ok, err, errcode = install.run(url, deps.deps_mode_to_flag(deps_mode)) |
| 492 | if not ok then | 493 | if not ok then |
| 493 | return nil, "Failed installing dependency: "..url.." - "..err, errcode | 494 | return nil, "Failed installing dependency: "..url.." - "..err, errcode |
diff --git a/src/luarocks/install.lua b/src/luarocks/install.lua index c938aa9f..ae162b86 100644 --- a/src/luarocks/install.lua +++ b/src/luarocks/install.lua | |||
| @@ -168,7 +168,6 @@ function install.run(...) | |||
| 168 | if not ok then return nil, err, cfg.errorcodes.PERMISSIONDENIED end | 168 | if not ok then return nil, err, cfg.errorcodes.PERMISSIONDENIED end |
| 169 | 169 | ||
| 170 | if name:match("%.rockspec$") or name:match("%.src%.rock$") then | 170 | if name:match("%.rockspec$") or name:match("%.src%.rock$") then |
| 171 | util.printout("Using "..name.."... switching to 'build' mode") | ||
| 172 | local build = require("luarocks.build") | 171 | local build = require("luarocks.build") |
| 173 | return build.run(name, util.forward_flags(flags, "local", "keep", "deps-mode", "only-deps")) | 172 | return build.run(name, util.forward_flags(flags, "local", "keep", "deps-mode", "only-deps")) |
| 174 | elseif name:match("%.rock$") then | 173 | elseif name:match("%.rock$") then |
| @@ -190,7 +189,7 @@ function install.run(...) | |||
| 190 | if not url then | 189 | if not url then |
| 191 | return nil, err | 190 | return nil, err |
| 192 | end | 191 | end |
| 193 | util.printout("Installing "..url.."...") | 192 | util.printout("Installing "..url) |
| 194 | return install.run(url, util.forward_flags(flags)) | 193 | return install.run(url, util.forward_flags(flags)) |
| 195 | end | 194 | end |
| 196 | end | 195 | end |
