]> git.phdru.name Git - dotfiles.git/commitdiff
.bashrc: Separate two tests for the case the dir doesn't exist
authorOleg Broytman <phd@phdru.name>
Thu, 9 Nov 2023 10:58:59 +0000 (13:58 +0300)
committerOleg Broytman <phd@phdru.name>
Thu, 9 Nov 2023 10:58:59 +0000 (13:58 +0300)
.bashrc

diff --git a/.bashrc b/.bashrc
index 12b8016d1e6b3db66054ba5d33afdc83920a5135..48b9a041f0ea5018f9c89078f86845e0fcd8cae7 100644 (file)
--- a/.bashrc
+++ b/.bashrc
@@ -143,8 +143,8 @@ DELEGATE_NOSPACE=1 delegate_completion rsync r rsync_cgmn rsync_cgmn_recode rsyn
 delegate_completion ssh s
 delegate_completion wget wget-m wget-wrapper ww
 
-if [ -d "$HOME"/.bash_completion.d -a \
-        -n "`ls -A $HOME/.bash_completion.d`" ]; then
+if [ -d "$HOME"/.bash_completion.d ] &&
+        -n "`ls -A $HOME/.bash_completion.d`" ]; then
     for _compf in "$HOME"/.bash_completion.d/*; do
         . $_compf
     done