1
0
forked from x/icebergs
icebergs/misc/node/npm.go
2023-06-03 10:16:57 +08:00

24 lines
397 B
Go

package node
import (
"shylinux.com/x/ice"
"shylinux.com/x/icebergs/base/cli"
"shylinux.com/x/icebergs/base/nfs"
)
const NPM = "npm"
type npm struct {
ice.Code
list string `name:"list path auto" help:"npm"`
}
func (s npm) Init(m *ice.Message) {
cli.IsAlpine(m.Message, NPM)
}
func (s npm) List(m *ice.Message) {
m.Cmdy(nfs.DIR, ice.USR_MODULES)
}
func init() { ice.CodeCtxCmd(npm{}) }