mirror of
https://github.com/martinvonz/jj.git
synced 2025-02-04 10:51:37 +00:00
788831fed3
Our support for aliases is very naively implemented; it assumes the alias is the first argument in argv. It therefore fails to resolve aliases after global arguments such as `--at-op`. This patch fixes that by modifying the command defintion to have an "external subcommand" in the list of available commands. That makes `clap` give us the remainder of the arguments when it runs into an unknown command. The first in the list will then be an alias or simply an unknown command. Thanks to @epage for the suggestion on in clap-rs/clap#3672. With the new structure, it was easy to handle recursive alias definitions, so I added support for that too. Closes #292. |
||
---|---|---|
.. | ||
commands.rs | ||
config.rs | ||
diff_edit.rs | ||
formatter.rs | ||
graphlog.rs | ||
lib.rs | ||
main.rs | ||
template.pest | ||
template_parser.rs | ||
templater.rs | ||
ui.rs |