diff options
author | Hisham Muhammad <hisham@gobolinux.org> | 2018-06-19 11:09:39 -0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2018-07-01 15:51:13 -0300 |
commit | e0af9ea7a7d7ba2aba76f975bf0d1c9965649ab8 (patch) | |
tree | 27279d0e330d2a4d11cd5163a639ec3921ef215b /src/bin/luarocks-admin | |
parent | 10ee65ec23a9b107c712bd7b017083c9a5571b0c (diff) | |
download | luarocks-e0af9ea7a7d7ba2aba76f975bf0d1c9965649ab8.tar.gz luarocks-e0af9ea7a7d7ba2aba76f975bf0d1c9965649ab8.tar.bz2 luarocks-e0af9ea7a7d7ba2aba76f975bf0d1c9965649ab8.zip |
cmd: new command-line initialization sequence
Diffstat (limited to 'src/bin/luarocks-admin')
-rwxr-xr-x | src/bin/luarocks-admin | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/bin/luarocks-admin b/src/bin/luarocks-admin index 4521ac26..e27b8c01 100755 --- a/src/bin/luarocks-admin +++ b/src/bin/luarocks-admin | |||
@@ -1,14 +1,11 @@ | |||
1 | #!/usr/bin/env lua | 1 | #!/usr/bin/env lua |
2 | 2 | ||
3 | -- this should be loaded first. | ||
4 | local cfg = require("luarocks.core.cfg") | ||
5 | |||
6 | local loader = require("luarocks.loader") | 3 | local loader = require("luarocks.loader") |
7 | local cmd = require("luarocks.cmd") | 4 | local cmd = require("luarocks.cmd") |
8 | 5 | ||
9 | program_description = "LuaRocks repository administration interface" | 6 | local description = "LuaRocks repository administration interface" |
10 | 7 | ||
11 | commands = { | 8 | local commands = { |
12 | help = "luarocks.cmd.help", | 9 | help = "luarocks.cmd.help", |
13 | make_manifest = "luarocks.admin.cmd.make_manifest", | 10 | make_manifest = "luarocks.admin.cmd.make_manifest", |
14 | add = "luarocks.admin.cmd.add", | 11 | add = "luarocks.admin.cmd.add", |
@@ -16,4 +13,4 @@ commands = { | |||
16 | refresh_cache = "luarocks.admin.cmd.refresh_cache", | 13 | refresh_cache = "luarocks.admin.cmd.refresh_cache", |
17 | } | 14 | } |
18 | 15 | ||
19 | cmd.run_command(...) | 16 | cmd.run_command(description, commands, ...) |