environment variable edit error
First check that your path variable is working or not just type (echo $PATH) from terminal it will return the O/P like: /usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin 
if saying "commond not found"

Then you have to PATH variable to setup path variable below steps

1) vi /etc/paths 
it's will vi editor to edit type "I" and enter below mention lines

/usr/local/bin
/usr/bin
/bin
/usr/sbin
/sbin

2) press esc and type wq to save exit.