0

I have a problem in my terminal. I've just downloaded an Android emulator and this happens on my terminal. I've been using Ubuntu 12.04.

Command 'lesspipe' is available in the following places
 * /bin/lesspipe
 * /usr/bin/lesspipe
The command could not be located because '/usr/bin:/bin' is not included in the PATH environment variable.
lesspipe: command not found
Command 'dircolors' is available in '/usr/bin/dircolors'
The command could not be located because '/usr/bin' is not included in the PATH environment variable.
dircolors: command not found
Command 'uname' is available in '/bin/uname'
The command could not be located because '/bin' is not included in the PATH environment variable.
uname: command not found
bash: [: =: unary operator expected
Command 'sed' is available in '/bin/sed'
The command could not be located because '/bin' is not included in the PATH environment variable.
sed: command not found
Command 'ls' is available in '/bin/ls'
The command could not be located because '/bin' is not included in the PATH environment variable.
ls: command not found
6

2 Answers 2

1

Run the following:

export PATH=/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin:/home/sweet/android-sdk-linux/platfrom-tools

Now try to execute the commands.

if you want to save it permanently so that you don't need to type it over and over again open ~/.bashrc using gedit by /usr/bin/gedit ~/.bashrc and find the line {PATH}:/home/sweet/android-sdk-linux/platfrom-tools. Then either delete that line or put a # in front of it to comment it out. Then add the following line:

export PATH=/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin:/home/sweet/android-sdk-linux/platfrom-tools

now save the file and from the terminal run source ~/.bashrc so that your path is properly set from the current terminal session.

16
  • it doesnt work.. Feb 19, 2015 at 4:30
  • whats the error message showing now?
    – heemayl
    Feb 19, 2015 at 4:31
  • there's no message.. Feb 19, 2015 at 4:35
  • i did it but when i trying to open gedit Command 'gedit' is available in '/usr/bin/gedit' The command could not be located because '/usr/bin' is not included in the PATH environment variable. gedit: command not found Feb 19, 2015 at 4:39
  • @SweetzelynSarmiento: Did you run export PATH=/bin:/usr/bin:/usr/local/bin:$PATH beforehand?
    – heemayl
    Feb 19, 2015 at 4:42
1

Just run the following: ctrl+alt+f2 Login your account with username and password.

sudo mv /etc/environment /etc/environment.bak
sudo touch /etc/environment
sudo reboot
1
  • Underrated answer May 19, 2021 at 15:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.