blob: 56f62f0ca74607fb867ff5d6cb5b0f932265d6d1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
module("luci.lpk", package.seeall)
require("luci.lpk.util")
require("luci.lpk.core")
__appname__ = "LuCI »lpk« Package Manager"
__version__ = "0.1"
__authors__ = "Steven Barth, Jo-Philipp Wich"
__cpyrght__ = string.format("Copyright (c) 2008 %s", __authors__)
__welcome__ = string.format("%s v%s\n%s",
__appname__, __version__, __cpyrght__)
options, arguments = luci.lpk.util.getopt(arg)
config = luci.util.dtable()
local cfgdump = loadfile("/etc/lpk.conf")
if cfgdump then
setfenv(cfgdump, config)
pcall(cfgdump)
end
if #arguments < 1 then
print(__welcome__)
print([[
Usage:
lpk [options] <command> [arguments]
lpk [options] install|remove pkg1 [pkg2] [...] [pkgn]
Commands:
install - Install packages
remove - Remove packages
purge - Remove packages and their configuration files
Options:
--force-depends - Ignore unresolvable dependencies
]])
else
-- Start machine
end
|