From 24dfe678071f359b49852432494ec313c12fefef Mon Sep 17 00:00:00 2001 From: Daylin Morgan Date: Wed, 22 Feb 2023 15:25:19 -0600 Subject: [PATCH] fix zexists sourcing --- .../zsh/plugins/zexists/zexists.plugin.zsh | 5 ++--- home/private_dot_config/zsh/zexists.d/cmd/anti-lsd.zsh | 1 + 2 files changed, 3 insertions(+), 3 deletions(-) create mode 100644 home/private_dot_config/zsh/zexists.d/cmd/anti-lsd.zsh diff --git a/home/private_dot_config/zsh/plugins/zexists/zexists.plugin.zsh b/home/private_dot_config/zsh/plugins/zexists/zexists.plugin.zsh index 15c3f71..4d76329 100644 --- a/home/private_dot_config/zsh/plugins/zexists/zexists.plugin.zsh +++ b/home/private_dot_config/zsh/plugins/zexists/zexists.plugin.zsh @@ -22,10 +22,9 @@ function source-zshcmdd { # sort and source conf files for rcfile in ${(o)conf_files}; do # ignore files that begin with a tilde and antircfiles - case ${rcfile:t} in 'anti'*|'~'*) continue;; esac - + case ${rcfile:t} in 'anti'* | '~'*) continue;; esac # source files only if exe with that name exists - if (( ! $+commands[{rcfile:t:r}] )); then + if (( $+commands[${rcfile:t:r}] )); then source "$rcfile" else # if it doesn't exist try the anti version diff --git a/home/private_dot_config/zsh/zexists.d/cmd/anti-lsd.zsh b/home/private_dot_config/zsh/zexists.d/cmd/anti-lsd.zsh new file mode 100644 index 0000000..cf53d10 --- /dev/null +++ b/home/private_dot_config/zsh/zexists.d/cmd/anti-lsd.zsh @@ -0,0 +1 @@ +alias lt="tree -L 3"