33
33
type cmdInstall struct {
34
AllowUnauthenticated bool `long:"allow-unauthenticated" description:"Install snaps even if the signature can not be verified."`
35
DisableGC bool `long:"no-gc" description:"Do not clean up old versions of the package."`
34
AllowUnauthenticated bool `long:"allow-unauthenticated"`
35
DisableGC bool `long:"no-gc"`
36
36
Positional struct {
37
PackageName string `positional-arg-name:"package name" description:"The Package to install (name or path)"`
38
ConfigFile string `positional-arg-name:"config file" description:"The configuration for the given install"`
37
PackageName string `positional-arg-name:"package name"`
38
ConfigFile string `positional-arg-name:"config file"`
39
39
} `positional-args:"yes"`
43
_, err := parser.AddCommand("install",
43
arg, err := parser.AddCommand("install",
44
44
i18n.G("Install a snap package"),
45
45
i18n.G("Install a snap package"),
48
48
logger.Panicf("Unable to install: %v", err)
50
addOptionDescription(arg, "allow-unauthenticated", i18n.G("Install snaps even if the signature can not be verified."))
51
addOptionDescription(arg, "no-gc", i18n.G("Do not clean up old versions of the package."))
52
addOptionDescription(arg, "package name", i18n.G("The Package to install (name or path)"))
53
addOptionDescription(arg, "config file", i18n.G("The configuration for the given install"))
52
56
func (x *cmdInstall) Execute(args []string) error {