mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
2198b0568f
This adjusts `command.PromptForConfirmation` in `cli/command/utils.go` to use `bufio`'s `ReadLine` rather than using `fmt.Fscan` for reading input, which makes `<Enter>` properly accept the default value of "No" as one would expect. This new code actually came from `cli/command/plugin/install.go`'s `acceptPrivileges` function, which I've also refactored here to use `command.PromptForConfirmation` as it should. Additionally, this updates `cli/command/plugin/upgrade.go`'s `runUpgrade` function to use `command.PromptForConfirmation` for further consistency. Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com> |
||
---|---|---|
.. | ||
bundlefile | ||
checkpoint | ||
commands | ||
container | ||
formatter | ||
idresolver | ||
image | ||
inspect | ||
network | ||
node | ||
plugin | ||
prune | ||
registry | ||
secret | ||
service | ||
stack | ||
swarm | ||
system | ||
task | ||
volume | ||
cli.go | ||
events_utils.go | ||
in.go | ||
out.go | ||
registry.go | ||
trust.go | ||
utils.go |