Skip to content

Commit

Permalink
Merge pull request #3277 from alrs/kops-command-fixes
Browse files Browse the repository at this point in the history
Automatic merge from submit-queue

Kops command fixes

TrimSuffix() on defaultStateStore doesn't actually do anything, and there is an unused answer variable in the tests.
  • Loading branch information
Kubernetes Submit Queue committed Aug 26, 2017
2 parents cc6fb51 + 408b11d commit 847f6de
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmd/kops/delete_confirm_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func TestConfirmation(t *testing.T) {
}

c.Default = "yes"
answer, err = ui.GetConfirm(c)
_, err = ui.GetConfirm(c)
if err != nil {
t.Fatal(err)
}
Expand Down
2 changes: 1 addition & 1 deletion cmd/kops/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ func NewCmdRoot(f *util.Factory, out io.Writer) *cobra.Command {

defaultStateStore := os.Getenv("KOPS_STATE_STORE")
if strings.HasSuffix(defaultStateStore, "/") {
strings.TrimSuffix(defaultStateStore, "/")
defaultStateStore = strings.TrimSuffix(defaultStateStore, "/")
}
cmd.PersistentFlags().StringVarP(&rootCommand.RegistryPath, "state", "", defaultStateStore, "Location of state storage")

Expand Down

0 comments on commit 847f6de

Please sign in to comment.