You should also look at /etc/profile
file, as it may have references to /etc/profile.d/rvm.sh
.
It's also worth it to read the manual for bash, as it lists all files bash will look at for configuration. This will be towards the end of the man page. To read it, in Terminal.app type man bash
.
Finally, you can run, again in Terminal.app, the following command:
grep -R 'rvm.sh' /etc
This will look for all files inside /etc
, recursively, that contain rvm.sh
text in them.
Modify the file .bash_profile with nano or another appropriate editor:
Replace:
export PATH=’/usr/local/bin:??
# Setting PATH for Python 2.7
# The orginal version is saved in .bash_profile.pysave
PATH="/Library/Frameworks/Python.framework/Versions/2.7/bin:${PATH}"
export PATH
by:
# Setting PATH for Python 2.7
# The orginal version is saved in .bash_profile.pysave
export PATH=/Library/Frameworks/Python.framework/Versions/2.7/bin:$PATH
Explanation:
The first line of your current .bash_profile
export PATH=’/usr/local/bin:??
modifies the standard value of $PATH given by /etc/paths from
/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
to ’/usr/local/bin:??
- which is no valid path.
The fourth and fifth line of your current .bash_profile modifies $PATH to
/Library/Frameworks/Python.framework/Versions/2.7/bin:’/usr/local/bin:??
Since ’/usr/local/bin:?
is no valid path the finally effective PATH is
/Library/Frameworks/Python.framework/Versions/2.7/bin
which completely breaks your standard PATH. You can still execute all executables in the above directories but you can't omit the superior directories (e.g. to execute nano you have to enter /usr/bin/nano
instead of nano
).
Best Answer
I was able to solve this issue with the following steps:
Open .zshrc and edit it. This can be done with the following:
From here, you may find a file, whatever it may be named (in this case, it was
sourceme.sh
). Delete the line that was installed in there. There are many reasons it's in there using nano. Then, save.Where
sourceme.sh
came from: I downloaded another program that automatically wrote that line in when I configured it, and when I deleted, it could no longer find that file. It could be any other shell script (.sh).