From 5fd85405b30683a0c308c5f4edc030ac3267dfa6 Mon Sep 17 00:00:00 2001 From: Arnaud Venturi Date: Mon, 7 May 2018 13:37:09 +0200 Subject: [PATCH] Fixed the style of the test again --- src/widgets.zsh | 4 ++-- zsh-autosuggestions.zsh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/widgets.zsh b/src/widgets.zsh index 190ddce..dfbf214 100644 --- a/src/widgets.zsh +++ b/src/widgets.zsh @@ -167,7 +167,7 @@ _zsh_autosuggest_partial_accept() { # In vicmd keymap, the cursor is placed on the current character # instead of after it. We increment it by 1 to keep the following logic # working even in thi case. - if [ $KEYMAP = 'vicmd' ]; then + if [[ "$KEYMAP" = "vicmd" ]]; then (( CURSOR++ )) fi @@ -184,7 +184,7 @@ _zsh_autosuggest_partial_accept() { fi # Restore CURSOR - if [ $KEYMAP = 'vicmd' ]; then + if [[ "$KEYMAP" = "vicmd" ]]; then (( CURSOR-- )) fi diff --git a/zsh-autosuggestions.zsh b/zsh-autosuggestions.zsh index 931598f..f21f897 100644 --- a/zsh-autosuggestions.zsh +++ b/zsh-autosuggestions.zsh @@ -445,7 +445,7 @@ _zsh_autosuggest_partial_accept() { # In vicmd keymap, the cursor is placed on the current character # instead of after it. We increment it by 1 to keep the following logic # working even in thi case. - if [ $KEYMAP = 'vicmd' ]; then + if [[ "$KEYMAP" = "vicmd" ]]; then (( CURSOR++ )) fi @@ -462,7 +462,7 @@ _zsh_autosuggest_partial_accept() { fi # Restore CURSOR - if [ $KEYMAP = 'vicmd' ]; then + if [[ "$KEYMAP" = "vicmd" ]]; then (( CURSOR-- )) fi