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

Help: how can I get nested sub command unknown message gracefully #1703

Closed
xavier-hou opened this issue May 18, 2022 · 1 comment
Closed
Labels
kind/support Questions, supporting users, etc.

Comments

@xavier-hou
Copy link

For example, I have a root command with sub-command run. And sub command run have a nested sub-command test.

Suppose that my command line called foo. The problem is if I use foo set, it will print the error message unknown command "set" for "foo". But if I use a wrong command like foo run set, it will just print the usage rather than unknown sub command "set" for "run".

My question is how can I get the nested sub-command unknown message gracefully just like command?

#706

@jpmcb jpmcb added the kind/support Questions, supporting users, etc. label May 19, 2022
@github-actions
Copy link

The Cobra project currently lacks enough contributors to adequately respond to all issues. This bot triages issues and PRs according to the following rules:

  • After 60d of inactivity, lifecycle/stale is applied. - After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied and the issue is closed.
    You can:
  • Make a comment to remove the stale label and show your support. The 60 days reset. - If an issue has lifecycle/rotten and is closed, comment and ask maintainers if they'd be interseted in reopening

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/support Questions, supporting users, etc.
Projects
None yet
Development

No branches or pull requests

2 participants