I have the following for loop:
for f in ~/.lo-rcs/common/*
do
. $f
done
which is returning this error:
bash: /home/sk/.lo-rcs/common/*: No such file or directory
I keep classifying my bashrc commands into multiple separate files and keeping them under $HOME/.lo-rcs/common
. I want all the files to be sourced into Bash automatically, but it keeps throwing the "no such file..." error.
Question
Why isn't Bash searching for files with the same name as the globbing pattern string?
- NOTE #1:
.lo-rcs/common
is my local rc configuration folder that contains separate files for aliases, one for export variables, one for functions etc. for ease of maintenance. - NOTE #2: All the files under
.lo-rcs/common
are hidden files, aka. files that are preceded by a dot.