Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Command = &command.C{ Name: "status", Help: "Print the status of the storage server.", Run: command.Adapt(func(env *command.Env) error { cfg := env.Config.(*config.Settings) return cfg.WithStore(env.Context(), func(s config.CAS) error { cs, ok := s.Base().(chirpstore.CAS) if !ok { return errors.New("store does not support the status command") } data, err := cs.Status(env.Context()) if err != nil { return err } fmt.Println(config.ToJSON(json.RawMessage(data))) return nil }) }), }
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.