mirror of
https://github.com/systemd/systemd
synced 2024-07-21 02:05:05 +00:00
bash-completion: update options for bootctl
This commit is contained in:
parent
3f0d8b2dbd
commit
2789437be5
|
@ -31,13 +31,13 @@ _bootctl() {
|
|||
local i verb comps
|
||||
local cur=${COMP_WORDS[COMP_CWORD]} prev=${COMP_WORDS[COMP_CWORD-1]}
|
||||
local -A OPTS=(
|
||||
[STANDALONE]='-h --help --no-variables -p --print-path --version --no-pager'
|
||||
[ARG]='--path'
|
||||
[STANDALONE]='-h --help --no-variables -p --print-esp-path -x --print-boot-path --version --no-pager'
|
||||
[ARG]='--esp-path --boot-path'
|
||||
)
|
||||
|
||||
if __contains_word "$prev" ${OPTS[ARG]}; then
|
||||
case $prev in
|
||||
--path)
|
||||
--esp-path|--boot-path)
|
||||
if [[ -z $cur ]]; then
|
||||
comps=$(compgen -A directory -- "/" )
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue