MacOS appear command not found

MacOS enter basic command prompt command not found.

Regardless of the input or nothing appears no such file or directory, it may be time configuration environment variable configuration errors.

You can try to resolve through the following scenario.

Open the terminal, enter the command:

export PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin

Be modified ~ / .bash_profile in

vim ~/.bash_profile

Look to see if there is content, if not then added to it:

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

Save and Exit After the addition is complete, enter the command to validate the configuration:

source ~/.bash_profile

Guess you like

Origin www.cnblogs.com/liuhuan086/p/11896999.html