From 47fb31b3896a63ddee824567460dc9e8ebf3eaa5 Mon Sep 17 00:00:00 2001 From: Harald Pfeiffer Date: Sat, 25 May 2024 12:57:51 +0200 Subject: include ~/.local/bin as well, only include dirs that are descendible into --- .bash/vars.bash | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.bash/vars.bash b/.bash/vars.bash index 773d75d..da222b1 100644 --- a/.bash/vars.bash +++ b/.bash/vars.bash @@ -18,9 +18,11 @@ SSHAGH+=( "woschd.example.com" ) export SSHAGH # ----- SHELL ----- # -for pa in "/usr/local/bin" "${HOME}/bin";do - if ! printf "%b" "$PATH"|grep -P "^${pa}:|:${pa}:" >/dev/null;then - export PATH="${pa}:${PATH}" +for pa in "/usr/local/bin" "${HOME}/bin" "${HOME}/.local/bin";do + if [ -x "$pa" ]; then + if ! printf "%b" "$PATH"|grep -P "^${pa}:|:${pa}:" >/dev/null;then + export PATH="${pa}:${PATH}" + fi fi done # $OSNAME -- cgit v1.2.3