Files
shadowdaoandClaude Sonnet 5.5 962d708fdd Rename Go module paths to repo.anhonesthost.net/CyberCoveLLC/threshold
Rename root, api and sdk module paths (imports, go.mod, go_package,
ldflags, build scripts, buf configs) and regenerate protobuf/gateway
code with the project's pinned toolchain. Wire identifiers unchanged.
api gets a local replace for sdk; root/api/sdk require v0.1.0.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-12 10:33:41 -07:00

61 lines
1.3 KiB
Go

// Copyright IBM Corp. 2020, 2026
// SPDX-License-Identifier: BUSL-1.1
package cache
import (
"strings"
"repo.anhonesthost.net/CyberCoveLLC/threshold/internal/cmd/base"
"github.com/mitchellh/cli"
"github.com/posener/complete"
)
var (
_ cli.Command = (*StartCommand)(nil)
_ cli.CommandAutocomplete = (*StartCommand)(nil)
)
type CacheCommand struct {
*base.Command
}
func (c *CacheCommand) Synopsis() string {
return "Manages the client side Threshold cache"
}
func (c *CacheCommand) Help() string {
helpText := `
Usage: threshold cache [sub command] [options]
This command allows interacting with the Threshold cache.
Start a cache:
$ threshold cache start
For a full list of examples, please see the documentation.
`
return strings.TrimSpace(helpText)
}
func (c *CacheCommand) Flags() *base.FlagSets {
return c.FlagSet(base.FlagSetNone)
}
func (c *CacheCommand) AutocompleteArgs() complete.Predictor {
return complete.PredictNothing
}
func (c *CacheCommand) AutocompleteFlags() complete.Flags {
return c.Flags().Completions()
}
func (c *CacheCommand) Run(args []string) int {
if len(args) >= 2 && args[1] == "daemon" {
c.UI.Warn("The `threshold daemon` command is deprecated, use `threshold cache` instead")
}
return cli.RunResultHelp
}