consistencyCmd returns a command to check the consistency of the posixfs storage.
(cfg *config.Config)
| 140 | |
| 141 | // consistencyCmd returns a command to check the consistency of the posixfs storage. |
| 142 | func consistencyCmd(cfg *config.Config) *cobra.Command { |
| 143 | consCmd := &cobra.Command{ |
| 144 | Use: "consistency", |
| 145 | Short: "check the consistency of the posixfs storage", |
| 146 | RunE: func(cmd *cobra.Command, args []string) error { |
| 147 | return checkPosixfsConsistency(cmd, cfg) |
| 148 | }, |
| 149 | } |
| 150 | consCmd.Flags().StringP("root", "r", "", "Path to the root directory of the posixfs storage") |
| 151 | _ = consCmd.MarkFlagRequired("root") |
| 152 | |
| 153 | return consCmd |
| 154 | } |
| 155 | |
| 156 | // checkPosixfsConsistency checks the consistency of the posixfs storage. |
| 157 | func checkPosixfsConsistency(cmd *cobra.Command, cfg *config.Config) error { |
no test coverage detected