From e04382358b5a2940adeba7c4e6c2f2e42dd1d0b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Schaerer?= Date: Thu, 30 Sep 2010 14:37:43 +0200 Subject: [PATCH] tentative fix of corner case path bug --- autojump.bash | 2 +- autojump.zsh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/autojump.bash b/autojump.bash index a1b8747..8d21b7d 100644 --- a/autojump.bash +++ b/autojump.bash @@ -26,7 +26,7 @@ _autojump() } complete -F _autojump j data_dir=${XDG_DATA_HOME:-$([ -e ~/.local/share ] && echo ~/.local/share || echo ~)} -if [ "$data_dir" = "~" ] +if [[ "$data_dir" = "${HOME}" ]] then export AUTOJUMP_DATA_DIR=${data_dir} else diff --git a/autojump.zsh b/autojump.zsh index 310a292..3079aff 100755 --- a/autojump.zsh +++ b/autojump.zsh @@ -15,7 +15,7 @@ #along with autojump. If not, see . local data_dir=${XDG_DATA_HOME:-$([ -e ~/.local/share ] && echo ~/.local/share || echo ~)} -if [ "$data_dir" = "~" ] +if [[ "$data_dir" = "${HOME}" ]] then export AUTOJUMP_DATA_DIR=${data_dir} else