I want to be able to add to my PATH when running a BASH shell script, but cannot get it to work. I have tried several different ways to achieve this from within a script, but none seem to work. I thought that (for example):
Code:
export PATH=${PATH}:~/bin
would work within the shell script, but it does not.
I have searched the forums and can find lots of information on how to set the PATH from within .profile, .bashrc, etc., but nothing on how to do it from within a 'normal' shell script.
If anyone could shed any light on this, I would appreciate it. Thanks.