Homepage GitHub

Confuse of yakut subcommand source code

I am reading yakut source code, I have some confuse:

in file main.py Line 200, this line is hard to read.

subcommand: Callable[..., Callable[..., Any]] = main.command

what is the relatitionship between with


and why no use



I am not sure what add_command() is supposed to do. We use the command decorator (here as main.command) as suggested by the docs, except that it is aliased for brevity as subcommand. I don’t see any issues with this code.