feat: 新增 proc.list/user.list/pkg.list 命令
proc.list 列出所有进程(ps aux/tasklist) user.list 列出系统用户(getent passwd/net user) pkg.list 列出已安装软件包(dpkg/rpm/apk/brew/winget)
This commit is contained in:
@@ -513,6 +513,15 @@ func Builtin() *Registry {
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
ID: "pkg.list",
|
||||
Group: "pkg",
|
||||
Summary: "列出已安装的软件包",
|
||||
Action: "列出系统中已安装的软件包。" +
|
||||
"Linux: dpkg -l(Debian/Ubuntu)/ rpm -qa(CentOS/RHEL)/ apk list(Alpine);" +
|
||||
"macOS: brew list;Windows: winget list",
|
||||
Variants: threePlatformBuiltins("pkg.list"),
|
||||
},
|
||||
{
|
||||
ID: "pkg.refreshindex",
|
||||
Group: "pkg",
|
||||
@@ -551,6 +560,14 @@ func Builtin() *Registry {
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
ID: "user.list",
|
||||
Group: "user",
|
||||
Summary: "列出系统用户",
|
||||
Action: "列出系统中所有用户账户。" +
|
||||
"Linux/macOS: getent passwd 或 /etc/passwd;Windows: net user",
|
||||
Variants: threePlatformBuiltins("user.list"),
|
||||
},
|
||||
{
|
||||
ID: "user.grant",
|
||||
Group: "user",
|
||||
@@ -720,6 +737,13 @@ func Builtin() *Registry {
|
||||
},
|
||||
|
||||
// ----- proc additions -----
|
||||
{
|
||||
ID: "proc.list",
|
||||
Group: "proc",
|
||||
Summary: "列出所有进程",
|
||||
Action: "列出系统中所有正在运行的进程。Linux/macOS: ps aux;Windows: tasklist",
|
||||
Variants: threePlatformBuiltins("proc.list"),
|
||||
},
|
||||
{
|
||||
ID: "proc.topmem",
|
||||
Group: "proc",
|
||||
|
||||
Reference in New Issue
Block a user