How to add subdirectories in PATH
Hi all!
I am relatively new to Linux, well this will probably be evident from my question. while writing a script I faced a problem of adding all the subdirctories of a certain directory in my path. I only know the way to add one directory at a time. i.e. export PATH=$PATH:ltp/kernel but what I want to do is to add all the subdirectories of directory kernel in my path for successful execution of my program. Please help me in this regard. Thanks in advance Regards MarcONI |
That sounds really strange that you want to put many entries to path.
Anyways, here it goes: Code:
DIRS=`echo /foo/bar/baz/*` |
hi marconi
Please take care of what forum you post your question in. This is the Linux-Certification forum, to discuss about the various certifications. There are many forums here at LQ. please choose the right forum so that your question gets the attention it deserves. This post has been reported and will soon be moved to an appropriate forum so don't create a new thread. Regards. |
Moved: This thread is more suitable in Linux-General and has been moved accordingly to help your thread/question get the exposure it deserves.
|
All times are GMT -5. The time now is 08:56 PM. |