Use our generate command instead of cobra's complete command

This commit is contained in:
Michael Eischer 2021-07-10 19:44:18 +02:00
parent 100baf74c0
commit 0880afe67b

View file

@ -119,6 +119,8 @@ func init() {
f.IntVar(&globalOptions.LimitUploadKb, "limit-upload", 0, "limits uploads to a maximum rate in KiB/s. (default: unlimited)")
f.IntVar(&globalOptions.LimitDownloadKb, "limit-download", 0, "limits downloads to a maximum rate in KiB/s. (default: unlimited)")
f.StringSliceVarP(&globalOptions.Options, "option", "o", []string{}, "set extended option (`key=value`, can be specified multiple times)")
// Use our "generate" command instead of the cobra provided "completion" command
cmdRoot.CompletionOptions.DisableDefaultCmd = true
restoreTerminal()
}