I know that in order to add a directory to my OS X path, I'm supposed to edit my ~/.bashrc or ~/.profile file to add something like:
export PATH=<<somepath>>:$PATH
I'm pretty new to bash and was wondering: would it be possible to edit, for instance, my ~/.bash_profile file so that I could do this dynamically, so that from the command line I could permanently add a directory to my path by doing something like
addpath <<somepath>>
instead?
PATH. There are many good reasons to keep yourPATHvery short, e.g.export PATH=/usr/bin:/bin:/usr/local/bin:$HOME/bin; so better add symlinks inside your$HOME/bin/directory.