mirror of
https://github.com/clap-rs/clap
synced 2024-12-14 23:02:31 +00:00
Merge #3054
3054: Allow bash completions to work with an alias r=pksunkara a=kurtbuilds Co-authored-by: Kurt Wolf <kurtwolfbuilds@gmail.com>
This commit is contained in:
commit
39374acb90
2 changed files with 4 additions and 4 deletions
|
@ -33,7 +33,7 @@ impl Generator for Bash {
|
|||
for i in ${{COMP_WORDS[@]}}
|
||||
do
|
||||
case \"${{i}}\" in
|
||||
{name})
|
||||
\"$1\")
|
||||
cmd=\"{cmd}\"
|
||||
;;{subcmds}
|
||||
*)
|
||||
|
|
|
@ -42,7 +42,7 @@ static BASH: &str = r#"_myapp() {
|
|||
for i in ${COMP_WORDS[@]}
|
||||
do
|
||||
case "${i}" in
|
||||
myapp)
|
||||
"$1")
|
||||
cmd="myapp"
|
||||
;;
|
||||
help)
|
||||
|
@ -139,7 +139,7 @@ static BASH_SPECIAL_CMDS: &str = r#"_my_app() {
|
|||
for i in ${COMP_WORDS[@]}
|
||||
do
|
||||
case "${i}" in
|
||||
my_app)
|
||||
"$1")
|
||||
cmd="my_app"
|
||||
;;
|
||||
help)
|
||||
|
@ -285,7 +285,7 @@ static BASH_ALIASES: &str = r#"_cmd() {
|
|||
for i in ${COMP_WORDS[@]}
|
||||
do
|
||||
case "${i}" in
|
||||
cmd)
|
||||
"$1")
|
||||
cmd="cmd"
|
||||
;;
|
||||
*)
|
||||
|
|
Loading…
Reference in a new issue