Skip to content
Discussion options

You must be logged in to vote

Your root command likely has an Action. Then foo goes to it as an argument, so CommandNotFound never runs. My tests (v3.14.0):

  • with Action, a2m foo - Action gets [foo]
  • without Action, a2m foo - "No such command foo"

For subcommands, set CommandNotFound on each parent. It does not inherit.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@stevewi-niteflyte
Comment options

Answer selected by stevewi-niteflyte
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants