Closed shannmu closed 3 days ago
The current code hasn't been tested a lot. I've just done some quick tests using the dynamic program from the tests. Also, for the CI, I'll rebase onto clap's master branch later and modify the commit message and a few other things to meet the CI requirements.
I need to split this PR into smaller PRs for easier discussion and review. How should I handle the situation where one resulting PR might be based on another PR?
I need to split this PR into smaller PRs for easier discussion and review. How should I handle the situation where one resulting PR might be based on another PR?
Either hold off on the follow up PRs or put them up, note the dependency, and rebase once the other PR is merged.
Related issues:
In this PR, I modified some logic in the complete function:
CompletionState
to record the current parsing state during completion parsing. When completion is triggered withtarget_cursor
equal tocursor
, the completion function will be chosen based on theCompletionState
.complete
function for arg over subcommand, optional long flag, escape, negative number, optional short flag, stdio, and empty.complete_arg
forarg
, with the same priority as above.There are some TODOs in this PR that I will implement later, including:
args_conflicts_with_subcommands
subcommand_precedence_over_arg
multicall