MCPcopy Index your code
hub / github.com/crowdsecurity/crowdsec / EnableCommand

Struct EnableCommand

pkg/hubops/enable.go:15–19  ·  view source on GitHub ↗

EnableCommand installs a hub item and its dependencies. In case this command is called during an upgrade, the sub-items list it taken from the latest version in the index, otherwise from the version that is currently installed.

Source from the content-addressed store, hash-verified

13// In case this command is called during an upgrade, the sub-items list it taken from the
14// latest version in the index, otherwise from the version that is currently installed.
15type EnableCommand struct {
16 Item *cwhub.Item
17 Force bool
18 FromLatest bool
19}
20
21func NewEnableCommand(item *cwhub.Item, force bool) *EnableCommand {
22 return &EnableCommand{Item: item, Force: force}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected