spf13 / cobra-cli

Cobra CLI tool to generate applications and commands

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow users to use exact command name in 'add -p'

Yeseh opened this issue · comments

Enhancement

Currently, the user of the cli has to append 'Cmd' to the parent command name when adding a child command.
I believe it would be a small improvement in the user experience if the command name could be used directly, as the user does in other commands.

Current behaviour:

cobra-cli add config
cobra-cli add set -p 'configCmd'

Proposed behaviour:

cobra-cli add config
cobra-cli add set -p config

Solution

A possible solution is to have the add command append 'Cmd' to the given parent command name, similar to how commandName is validated.

This issue is being marked as stale due to a long period of inactivity

This issue is being marked as stale due to a long period of inactivity

This issue is being marked as stale due to a long period of inactivity

This issue is being marked as stale due to a long period of inactivity