Skip to content

Commit

Permalink
fix flags in commands
Browse files Browse the repository at this point in the history
  • Loading branch information
0x46616c6b committed Apr 15, 2021
1 parent a8a81aa commit 18de13b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion cmd/copy-pad.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ var (
)

func init() {
copyPadCmd.LocalFlags().BoolVar(&forceCopy, "force", false, "If set and the destination pad exists, it will be overwritten.")
copyPadCmd.Flags().BoolVar(&forceCopy, "force", false, "If set and the destination pad exists, it will be overwritten.")

rootCmd.AddCommand(copyPadCmd)
}
Expand Down
2 changes: 1 addition & 1 deletion cmd/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ var (
)

func init() {
metricsCmd.LocalFlags().StringVar(&listenAddr, "listen.addr", ":9012", "")
metricsCmd.Flags().StringVar(&listenAddr, "listen.addr", ":9012", "")

rootCmd.AddCommand(metricsCmd)
}
Expand Down
2 changes: 1 addition & 1 deletion cmd/move-pad.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ var (
)

func init() {
movePadCmd.LocalFlags().BoolVar(&forceMove, "force", false, "If set and the destination pad exists, it will be overwritten.")
movePadCmd.Flags().BoolVar(&forceMove, "force", false, "If set and the destination pad exists, it will be overwritten.")

rootCmd.AddCommand(movePadCmd)
}
Expand Down
4 changes: 2 additions & 2 deletions cmd/purge.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ Pads with the suffix "-keep" will be deleted after 365 days of inactivity.
)

func init() {
purgeCmd.LocalFlags().IntVar(&concurrency, "concurrency", 4, "Concurrency for the purge process")
purgeCmd.LocalFlags().BoolVar(&dryRun, "dry-run", false, "Enable dry-run")
purgeCmd.Flags().IntVar(&concurrency, "concurrency", 4, "Concurrency for the purge process")
purgeCmd.Flags().BoolVar(&dryRun, "dry-run", false, "Enable dry-run")

rootCmd.AddCommand(purgeCmd)
}
Expand Down

0 comments on commit 18de13b

Please sign in to comment.