Merge "Fix bash autocompletion of "rally task sla_check""
This commit is contained in:
commit
ed5d5baba3
@ -50,8 +50,9 @@ _rally()
|
|||||||
|
|
||||||
|
|
||||||
for OPT in ${!OPTS[*]} ; do
|
for OPT in ${!OPTS[*]} ; do
|
||||||
CMDSUB=(${OPT//_/ })
|
CMD=${OPT%%_*}
|
||||||
SUBCOMMANDS[${CMDSUB[0]}]+="${CMDSUB[1]} "
|
CMDSUB=${OPT#*_}
|
||||||
|
SUBCOMMANDS[${CMD}]+="${CMDSUB} "
|
||||||
done
|
done
|
||||||
|
|
||||||
COMMANDS="${!SUBCOMMANDS[*]}"
|
COMMANDS="${!SUBCOMMANDS[*]}"
|
||||||
|
@ -445,8 +445,9 @@ _rally()
|
|||||||
%(data)s
|
%(data)s
|
||||||
|
|
||||||
for OPT in ${!OPTS[*]} ; do
|
for OPT in ${!OPTS[*]} ; do
|
||||||
CMDSUB=(${OPT//_/ })
|
CMD=${OPT%%%%_*}
|
||||||
SUBCOMMANDS[${CMDSUB[0]}]+="${CMDSUB[1]} "
|
CMDSUB=${OPT#*_}
|
||||||
|
SUBCOMMANDS[${CMD}]+="${CMDSUB} "
|
||||||
done
|
done
|
||||||
|
|
||||||
COMMANDS="${!SUBCOMMANDS[*]}"
|
COMMANDS="${!SUBCOMMANDS[*]}"
|
||||||
@ -489,4 +490,4 @@ complete -F _rally rally
|
|||||||
|
|
||||||
completion.append(""" OPTS["{cat}_{cmd}"]="{args}"\n""".format(
|
completion.append(""" OPTS["{cat}_{cmd}"]="{args}"\n""".format(
|
||||||
cat=category, cmd=name, args=args))
|
cat=category, cmd=name, args=args))
|
||||||
return bash_data % {"data": "".join(sorted(completion))}
|
return bash_data % {"data": "".join(sorted(completion))}
|
||||||
|
Loading…
Reference in New Issue
Block a user