From b2c2ed5ea350bdbb112adf6c5abd70afecdec028 Mon Sep 17 00:00:00 2001 From: V1K1NGbg Date: Mon, 29 Jul 2024 19:54:51 +0300 Subject: completely removing build.opts --- src/luarocks/cmd/build.lua | 6 ++---- src/luarocks/cmd/make.lua | 4 ++-- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/luarocks/cmd/build.lua b/src/luarocks/cmd/build.lua index 8049596f..b46b9532 100644 --- a/src/luarocks/cmd/build.lua +++ b/src/luarocks/cmd/build.lua @@ -51,7 +51,6 @@ end -- or false and an error message and an optional error code. local function build_rock(rock_filename, opts) assert(type(rock_filename) == "string") - assert(opts:type() == "build.opts") local cwd = fs.absolute_name(dir.path(".")) @@ -84,7 +83,6 @@ local function do_build(name, namespace, version, opts) assert(type(name) == "string") assert(type(namespace) == "string" or not namespace) assert(version == nil or type(version) == "string") - assert(opts:type() == "build.opts") local url, err if name:match("%.rockspec$") or name:match("%.rock$") then @@ -132,7 +130,7 @@ function cmd_build.command(args) return make.command(args) end - local opts = build.opts({ + local opts = { need_to_fetch = true, minimal_mode = false, deps_mode = deps.get_deps_mode(args), @@ -144,7 +142,7 @@ function cmd_build.command(args) pin = not not args.pin, rebuild = not not (args.force or args.force_fast), no_install = false - }) + } if args.sign and not args.pack_binary_rock then return nil, "In the build command, --sign is meant to be used only with --pack-binary-rock" diff --git a/src/luarocks/cmd/make.lua b/src/luarocks/cmd/make.lua index ffec8c5d..e7db6aad 100644 --- a/src/luarocks/cmd/make.lua +++ b/src/luarocks/cmd/make.lua @@ -99,7 +99,7 @@ function make.command(args) local name, namespace = util.split_namespace(rockspec.name) namespace = namespace or args.namespace - local opts = build.opts({ + local opts = { need_to_fetch = false, minimal_mode = true, deps_mode = deps.get_deps_mode(args), @@ -111,7 +111,7 @@ function make.command(args) pin = not not args.pin, rebuild = true, no_install = not not args.no_install - }) + } if args.sign and not args.pack_binary_rock then return nil, "In the make command, --sign is meant to be used only with --pack-binary-rock" -- cgit v1.2.3-55-g6feb