My Mac may be set wrong when setting environment variables, and now the whole Mac's vi,ls and other commands are not going to execute.

Source: Internet
Author: User
1, enter on the command line
Export Path=/usr/bin:/usr/sbin:/bin:/sbin:/usr/x11r6/bin
This guarantees that command-line commands can be used temporarily. Do not close the terminal until after the command has been executed
or execute the VI command under Cd/usr/bin.
2. Recover Bash_profile Files


3. It is possible that your PATH environment variable is set incorrectly, such as $PATH leaking
Path= $PATH: $PATH 1

4. Immediate effect, source ~/.bash_profile

My Mac may be set wrong when setting environment variables, and now the whole Mac's vi,ls and other commands are not going to execute.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.