From 540e75f56f49464233b579a50447a860f3d53e6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakobus=20Sch=C3=BCrz?= Date: Wed, 7 Jul 2021 16:36:50 +0200 Subject: [PATCH] fix ask for empty variable --- bashrc_add | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bashrc_add b/bashrc_add index db326f7..97ca255 100755 --- a/bashrc_add +++ b/bashrc_add @@ -72,8 +72,8 @@ if [[ $- = *i* ]] ; then # which dnf >/dev/null 2>&1 [ -z "${P11M+x}" ] && P11M="$(dnf repoquery --installed -l p11-kit | grep \/p11-kit-proxy.so\$ | head -1)" # which dpkg >/dev/null 2>&1 && [ -z "${P11M+x}" ] && P11M="$(dpkg -L p11-kit-modules|grep \/p11-kit-proxy.so\$ | head -1)" - [ -z "${PKCS11_MODULE+x}" ] && [ -n "$(whereis p11-kit-proxy.so|awk '{print $2}')" ] && export PKCS11_MODULE=$(whereis p11-kit-proxy.so|awk '{print $2}' || { echo "p11-kit-proxy not installed, unset KCS11_MODULE"; unset PKCS11_MODULE; }) - [ -z "${P11M+x}" ] && [ -n "$(whereis p11-kit-proxy.so|awk '{print $2}')" ] && export P11M=$(whereis p11-kit-proxy.so|awk '{print $2}' || { echo "p11-kit-proxy not forwarded by ssh or installed, unset P11M"; unset P11M; }) + [ -z "${PKCS11_MODULE:+x}" ] && [ -n "$(whereis p11-kit-proxy.so|awk '{print $2}')" ] && export PKCS11_MODULE=$(whereis p11-kit-proxy.so|awk '{print $2}' || { echo "p11-kit-proxy not installed, unset KCS11_MODULE"; unset PKCS11_MODULE; }) + [ -z "${P11M:+x}" ] && [ -n "$(whereis p11-kit-proxy.so|awk '{print $2}')" ] && export P11M=$(whereis p11-kit-proxy.so|awk '{print $2}' || { echo "p11-kit-proxy not forwarded by ssh or installed, unset P11M"; unset P11M; }) # Basics [ -z "${VISUAL+x}" ] && export VISUAL=vim