New to Unix, I recently tried to add a $PATH variable in Unix in order to debug my android sdk. I looked up online the directions and tried to follow them as thoroughly as possible. What ended up happening is that my basic commands no longer work (e.g. ls, man, cd etc...) I get a message stating "-bash: ls: command not found". I am not sure what I might have done. Maybe I might have wrote over the original file.
|
|
|||
|
|
migrated from stackoverflow.com Nov 21 '11 at 3:34
|
You probably overwrote your PATH variable instead of appending to it. My PATH variable on my computer right now (Ubuntu 11.10) looks like this: rvoliva@bobby-ubuntu:~$ echo $PATH /usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games I'm guessing yours doesn't have any of those bin folders in it at the moment. When you use export to modify your PATH, make sure you append to it: export PATH=/new/path/location/dir:$PATH |
|||||||||
|
|
You defined
If you leave off the |
|||
|