Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix progress bars not working #594

Merged
merged 2 commits into from
Sep 30, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cli/object_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ NOTE: This is an experimental feature.
put.Flag("name", "Override the name supplied to the object store").StringVar(&c.overrideName)
put.Flag("description", "Sets an optional description for the object").StringVar(&c.description)
put.Flag("header", "Adds headers to the object").Short('H').StringsVar(&c.hdrs)
put.Flag("progress", "Disables progress bars").Default("true").BoolVar(&c.noProgress)
put.Flag("no-progress", "Disable progress bars").UnNegatableBoolVar(&c.noProgress)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since the new cli library now have negatable booleans I think I'd rather like:

put.Flag("progress", "Disable progress bars").Default("true").BoolVar(&c.progress)

like in stream backup and restore, its a bit more in tune also with how we handle other boolean flags now

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. Update coming!

put.Flag("force", "Act without confirmation").Short('f').UnNegatableBoolVar(&c.force)

del := obj.Command("del", "Deletes a file or bucket from the store").Action(c.delAction).Alias("rm")
Expand All @@ -94,7 +94,7 @@ NOTE: This is an experimental feature.
get.Arg("bucket", "The bucket to act on").Required().StringVar(&c.bucket)
get.Arg("file", "The file to retrieve").Required().StringVar(&c.file)
get.Flag("output", "Override the output file name").Short('O').StringVar(&c.overrideName)
get.Flag("progress", "Disables progress bars").Default("true").BoolVar(&c.noProgress)
get.Flag("no-progress", "Disable progress bars").UnNegatableBoolVar(&c.noProgress)
get.Flag("force", "Act without confirmation").Short('f').UnNegatableBoolVar(&c.force)

info := obj.Command("info", "Get information about a bucket or object").Alias("show").Alias("i").Action(c.infoAction)
Expand Down