From ebc4fc84c0a9eb878192d1db51e5acc61610be45 Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Fri, 14 Feb 2020 09:55:16 -0300 Subject: make: support --only-deps Closes #1156. --- src/luarocks/cmd/make.lua | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/luarocks/cmd/make.lua b/src/luarocks/cmd/make.lua index 2db6c403..60a0f11e 100644 --- a/src/luarocks/cmd/make.lua +++ b/src/luarocks/cmd/make.lua @@ -62,9 +62,6 @@ commands. See the help on those for details. If the current directory contains a luarocks.lock file, it is used as the authoritative source for exact version of dependencies. The --pin flag overrides and recreates this file scanning dependency based on ranges. - -NB: Use `luarocks install` with the `--only-deps` flag if you want to install -only dependencies of the rockspec (see `luarocks help install`). ]], util.see_also()) :summary("Compile package in current directory using a rockspec.") @@ -102,7 +99,7 @@ function make.command(args) need_to_fetch = false, minimal_mode = true, deps_mode = deps.get_deps_mode(args), - build_only_deps = false, + build_only_deps = not not (args.only_deps and not args.pack_binary_rock), namespace = namespace, branch = args.branch, verify = not not args.verify, @@ -129,6 +126,12 @@ function make.command(args) if not ok then return nil, err end local name, version = ok, err + if opts.build_only_deps then + util.printout("Stopping after installing dependencies for " ..name.." "..version) + util.printout() + return name, version + end + if args.no_doc then util.remove_doc_dir(name, version) end -- cgit v1.2.3-55-g6feb