MCPcopy Create free account
hub / github.com/ByteYellow/AgentProvenance / initCmd

Function initCmd

internal/cli/init_cmd.go:9–22  ·  view source on GitHub ↗
(dataDir *string)

Source from the content-addressed store, hash-verified

7)
8
9func initCmd(dataDir *string) *cobra.Command {
10 return &cobra.Command{
11 Use: "init",
12 Short: "initialize local agentprov state",
13 RunE: func(cmd *cobra.Command, args []string) error {
14 paths, err := store.Init(*dataDir)
15 if err != nil {
16 return err
17 }
18 fmt.Fprintf(cmd.OutOrStdout(), "initialized %s\n", paths.Root)
19 return nil
20 },
21 }
22}

Callers 1

NewRootCommandFunction · 0.85

Calls 1

InitFunction · 0.92

Tested by

no test coverage detected