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

Rename list instances to get instances #258

Merged
merged 2 commits into from
May 23, 2019
Merged

Rename list instances to get instances #258

merged 2 commits into from
May 23, 2019

Conversation

alenkacz
Copy link
Contributor

What type of PR is this?
/component kudoctl

What this PR does / why we need it:
Moving away from kudo list instances to more kubectl-like feel with kudo get instances. It's just a proposal - we can discuss if everyone feels good about this move. I just talked about it with @fabianbaier and he was not opposed.

Which issue(s) this PR fixes:
None

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

`kubectl kudo list instances` now becomes `kubectl kudo get instances`

@alenkacz alenkacz requested a review from kensipe as a code owner May 22, 2019 09:26
@@ -28,14 +28,13 @@ const (
defaultConfigPath = ".kube/config"
)

// NewListInstancesCmd creates a command that lists the instances in the cluster
func NewListInstancesCmd() *cobra.Command {
Copy link
Member

Choose a reason for hiding this comment

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

Change the Command object's name as well

)

// NewGetInstancesCmd creates a command that lists the instances in the cluster
func NewGetInstancesCmd() *cobra.Command {
Copy link
Member

Choose a reason for hiding this comment

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

I don't quite understand why there are two commands, one in pkg and one in cmd. Which one is actually run? What's the purpose of the other one. This all isn't necessary for this PR though

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think Intellij must have done this somehow during refactoring. I definitely did not move any code around by myself... let me retry once more :)

Copy link
Member

Choose a reason for hiding this comment

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

Think you're ok, the one under pkg/kudoctl/cmd has been there a while. We may want to move the functionality of listing instances out to it's own package and not have cobra details inside of pkg/kudoctl/cmd - but like @runyontr said, that's another PR.

@alenkacz
Copy link
Contributor Author

@runyontr I think now it should be fine :)

)

// NewGetInstancesCmd creates a command that lists the instances in the cluster
func NewGetInstancesCmd() *cobra.Command {
Copy link
Member

Choose a reason for hiding this comment

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

Think you're ok, the one under pkg/kudoctl/cmd has been there a while. We may want to move the functionality of listing instances out to it's own package and not have cobra details inside of pkg/kudoctl/cmd - but like @runyontr said, that's another PR.

Copy link
Contributor

@joerg84 joerg84 left a comment

Choose a reason for hiding this comment

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

Just curious are there any other documentation/demos referencing the old command?
Would it make sense to have an alias with the old command?
Also, this should be mentioned in release notes being a breaking change, or?

Having that said, thanks for this PR :-)!

@alenkacz
Copy link
Contributor Author

@joerg84 I went over this whole repo, hopefully I fixed all the usages. I am not aware of any other. Also I've filled the release note part of the PR, I hope that is enough to get it propagated

@gerred
Copy link
Member

gerred commented May 23, 2019

@alenkacz squash+merge when ready. 👍

@alenkacz alenkacz merged commit c271412 into master May 23, 2019
@alenkacz alenkacz deleted the av/get-instances branch May 30, 2019 11:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants