-
Notifications
You must be signed in to change notification settings - Fork 14
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
Documentation by Object #348
Comments
One problem with that, the docs are currently automatically generated from the CLI structure using To do what you suggest would mean manual documentation changes, which we kind of want to avoid due to issues it brings. Generally though the
I know that isn't really ideal or solves your particular issue of having a list of commands that can be used on specific resources in Lagoon, but the alternative is potentially out of date documentation pages because the auto-generated docs won't update pages manually created. |
I agree with the goal of auto-generation, but wouldn't it be possible to set up an additional automatic generation where:
Cobra might not do that easily (XSLT would do it, but people seem to have turned their backs on XML just because it's better at documents than at being an on-the-wire protocol). HTH, |
Cobra generates the documentation based on the command structure. The only way to do what you are wanting here is to re-write the CLI with the command structure laid out in a different manner to the way they currently are, OR write some entirely new functionality outside of the CLI that would still need to be maintained in addition to maintaining the commands themselves. As it stands, I'm fairly confident this will not be resolvable in the short term in the current implementation of the CLI, and the team just doesn't have the resources available to invest in writing out an entirely separate autogeneration system to satisfy this level of documentation changes without considerable changes as described above. I will add this as a possible thing to consider when we think about re-writing the CLI in the future, but no guarantee that it will happen, but the rewrite (when/if it happens) will hopefully make things a bit clearer (and no there is no open issue or tracker for a rewrite, because there is no guarantee that we will do a rewrite at this point in time). Alternatively, if you've got the time to invest in working out how this could work in the current implementation, we're always open to reviewing pull requests, but that does not guarantee a merge either. Just wanting to set expectations around the work involved on this. |
Sure, fair enough. This sounds like a Cobra problem, not an Amazee problem. Thanks. |
Well, not really. Cobra just builds the documentation based on the command structure, it does what it does and it does it well. The problem you're describing is not a problem that I think cobra can solve. Cobra doesn't understand that one command could be linked to a specific object or not, because it doesn't exist in cobra. |
So the problem is that cobra only understands commands, not objects. Still sounds like a cobra problem :p . |
Is your feature request related to a problem? Please describe.
I often what to know what objects I can operate on, and what I can do to them
Describe the solution you'd like
If the docs had a page for each object (eg, "project", "user"), and listed:
...that'd be great.
Each command should just have a short description (ie. one line), and link to the main command page
Describe alternatives you've considered
Digging through the docs like I do now.
The text was updated successfully, but these errors were encountered: