I'm using Ubuntu and I'm trying to add a folder to my PATH that contains subfolders including my scripts.
My folder paths are:
/opt/tools/utils/my_script.sh
/opt/tools/steps/my_script.sh
Other scripts do exist, but my focus is on my_script.sh
I have a script, clone from a repo, that does:
export PATH=$PATH:/opt/tools, and then it calls utils/my_script.sh.
This works fine on my machine, but on my coworker's machine it shows that utils/my_script.sh is not a file or directory. How can this issue be resolved?
utils/my_script.shwould work even after adding/opt/toolsto$PATH. What I think is that you are runningutils/my_script.shin the directory that containsutilsdirectory. Can you show output ofls -Alandpwddone in the directory where you runutils/my_script.sh?