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

Add documentation for minikube CLI commands #4647

Merged

Conversation

blueelvis
Copy link
Contributor

@blueelvis blueelvis commented Jun 30, 2019

Fixes #4271

This is the first pass on documenting the options, commands and flags available in the minikube CLI.

I went ahead and added for all the commands and not only the start command as mentioned in the issue.

/assign tstromberg

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jun 30, 2019
@k8s-ci-robot
Copy link
Contributor

Hi @blueelvis. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jun 30, 2019
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: blueelvis
To complete the pull request process, please assign ra489
You can assign the PR to them by writing /assign @ra489 in a comment when ready.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@minikube-bot
Copy link
Collaborator

Can one of the admins verify this patch?

@afbjorklund
Copy link
Collaborator

These are very likely to get out of date, due to the duplication of information...

Could we use something automated, similar to help2man, to generate it ?

@RA489
Copy link

RA489 commented Jul 1, 2019

@minikube-bot OK to test

@tstromberg
Copy link
Contributor

tstromberg commented Jul 2, 2019

Thanks for this PR!

I do agree with afbjorklund@ - these docs are great right now, but will get stale very fast. The command-line framework we are using, Cobra, allows automatic generation of markdown docs.

https://github.com/spf13/cobra/blob/master/doc/md_docs.md

By auto-generating docs, we can guarantee that users who are using --help get the same rich help as those using our doc website. Here's an example using Cobra's VisitAll() that we could emulate - though my preference would be that each command gets it's own markdown file:

https://github.com/GoogleContainerTools/skaffold/blob/68fe5670b38a19cc5f689040ad2088c5bdeea779/cmd/skaffold/man/man.go#L38

@RA489
Copy link

RA489 commented Jul 3, 2019

@minikube-bot OK to test

@blueelvis
Copy link
Contributor Author

@afbjorklund @tstromberg - Agreed. Let me try using Cobra's auto generation and get back.

@tstromberg
Copy link
Contributor

tstromberg commented Jul 3, 2019

I thought about this some more: we should not let perfect be the enemy of good, particularly when it comes to documentation. If Cobra auto-generation turns out to be difficult, I would be rather accept this doc as is, and replace it with automation as soon as possible. Let me know how your experiment goes.

Thank you!

@blueelvis
Copy link
Contributor Author

@tstromberg @afbjorklund - This looks really promising. I generated the attached (start.txt) markdown file for the start command. After a couple of tweaks, it could look really good!

The cobra.Command accepts a lot of parameters which can be filled with Examples and other documentation! That would flesh out the documentation automatically.

Let me know if you are open to merge this PR now and I can work on another one meanwhile to integrate this with all of our commands and have something automated?

@RA489
Copy link

RA489 commented Jul 4, 2019

@minikube-bot OK to test

@blueelvis
Copy link
Contributor Author

ping @tstromberg

@tstromberg
Copy link
Contributor

Happy to merge this one now while we work out how to automate it. Thank you for writing this up!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Document all "start" options on the minikube website
6 participants