fixed navigate completion string comparison

This commit is contained in:
quak
2025-02-01 08:55:04 +01:00
parent 6006d9966e
commit 3bedd0bb0f

View File

@@ -28,12 +28,12 @@ function _book {
BOOKMARKS="add remove $(__call_navigate bookmark names)" BOOKMARKS="add remove $(__call_navigate bookmark names)"
COMPREPLY=($(compgen -W "${BOOKMARKS}" -- $CURRENT_WORD)) COMPREPLY=($(compgen -W "${BOOKMARKS}" -- $CURRENT_WORD))
elif [[ COMP_CWORD -eq 2 ]]; then elif [[ COMP_CWORD -eq 2 ]]; then
if [[ COMP_WORDS[1] -eq "remove" ]]; then if [[ COMP_WORDS[1] = "remove" ]]; then
BOOKMARKS="$(__call_navigate bookmark names)" BOOKMARKS="$(__call_navigate bookmark names)"
COMPREPLY=($(compgen -W "${BOOKMARKS}" -- $CURRENT_WORD)) COMPREPLY=($(compgen -W "${BOOKMARKS}" -- $CURRENT_WORD))
fi fi
elif [[ COMP_CWORD -eq 3 ]]; then elif [[ COMP_CWORD -eq 3 ]]; then
if [[ COMP_WORDS[1] -eq "add" ]]; then if [[ COMP_WORDS[1] = "add" ]]; then
COMPREPLY=($(compgen -o dirnames -- $CURRENT_WORD)) COMPREPLY=($(compgen -o dirnames -- $CURRENT_WORD))
fi fi
fi fi