From e106562ef13ef8f8de26c8b4b275c400d8f84ab2 Mon Sep 17 00:00:00 2001 From: Silent Crafter <63489080+Silent-Crafter@users.noreply.github.com> Date: Thu, 6 Jan 2022 09:52:59 +0530 Subject: [PATCH] Bash: for loop array iteration fix the array iteration wasn't implemented correctly for KITTY_SHELL_INTEGRATION variable. the i variable in for loop wasn't iterating through all the elements of that array --- shell-integration/bash/kitty.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell-integration/bash/kitty.bash b/shell-integration/bash/kitty.bash index cf32ee97b..f7cdd76c0 100644 --- a/shell-integration/bash/kitty.bash +++ b/shell-integration/bash/kitty.bash @@ -5,7 +5,7 @@ _ksi_main() { if [[ -z "$KITTY_SHELL_INTEGRATION" ]]; then return; fi declare -A _ksi_prompt=( [cursor]='y' [title]='y' [mark]='y' [complete]='y' ) set -f - for i in ${KITTY_SHELL_INTEGRATION}; do + for i in ${KITTY_SHELL_INTEGRATION[@]}; do set +f if [[ "$i" == "no-cursor" ]]; then _ksi_prompt[cursor]='n'; fi if [[ "$i" == "no-title" ]]; then _ksi_prompt[title]='n'; fi