[Go] Mac System terminal command line does not execute command always appears to found workaround

Source: Internet
Author: User

Configure the Android development environment, change bash_profile This file, finally somehow only the CD command can execute, I guess the Bash_profile file can be modified after not saving the resulting Save command is: source. bash_profile

Here's my solution:

1, on the command line, enter:

[CPP]View PlainCopyprint?
    1. 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.

2, enter

[CPP]View PlainCopyprint?
    1. CD ~/

Enter the home directory of the current user.

3, create bash_profile Execute command:

[CPP]View PlainCopyprint?
    1. Touch. Bash_profile

4. Open and edit the bash_profile Execute command:

[CPP]View PlainCopy print?
    1. Open. Bash_profile

5, so open a notepad, will show you previously configured path, modify Notepad, first delete all you feel useful can be in the desktop Backup, command line good after adding.

[CPP]View PlainCopyprint?
    1. Export java_home= '/usr/libexec/java_home '
[CPP]View PlainCopyprint?
    1. Export path=${path}:${java_home}:${android_sdk_root}:${android_sdk_root}/platform-tools:${android_sdk_root}/ Tools:${java_home}:${java_home}/bin
    2. Export path="/usr/local/bin:/usr/local/sbin:~/bin: $PATH"

The above is the system, if you want to configure something, such as the Android development environment in the SDK to add the directory, do not configure the words will not be added.

[CPP]View PlainCopyprint?
    1. Export android_sdk_root="/USERS/WANGKAI/DOCUMENTS/ADT-BUNDLE-MAC-X86_64-20130219/SDK"
I saved these 4 references in my command line 6, to save the full selection: Command+s or not at ease, select the Notepad file-save save after saving no prompt to directly turn off. 7, at this point, enter the update command at the command line (the command line is not closed): [CPP]View PlainCopyprint?
    1. source. bash_profile

OK, restart the terminal command line, eg: enter LS

[Go] Mac System terminal command line does not execute command always appears to found workaround

Related Article

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.