The help or ? function should show custom help text for a command when called with a command name.
I see three ways this can be implemented;
Like in Python Cmd where a do_command can have an associated help_command method that prints out the help tekst
Another way might be to have the cmdr macro parse the doc-comments for functions and use these as help tekst. Although this seems a bit 'magic' and might interfere how a user of the cmdr library wants to write documentation.
A third way is to annotate do_command with a help 'macro' that is picked up by the cmdr macro.
At the moment I lean towards implementing both option 1 and 3. Normally help methods will be used. Later an extra option can be implemented to easilly implement help methods with static text by using an annotiation.
The help or ? function should show custom help text for a command when called with a command name.
I see three ways this can be implemented;
At the moment I lean towards implementing both option 1 and 3. Normally help methods will be used. Later an extra option can be implemented to easilly implement help methods with static text by using an annotiation.