码迷,mamicode.com
首页 > 系统相关 > 详细

MAC 上找不到.bash_profile该怎么办?

时间:2016-08-29 22:13:41      阅读:238      评论:0      收藏:0      [点我收藏+]

标签:

 

 

 

开发Android的环境要重新在Mac上搭建,结果在配置环境变量时找不到.bash_profile文件。查过很多资料解决方案都很笼统,结果还是在英文网站上找到解决方法。

1. 启动终端Terminal

2. 进入当前用户的home目录

    输入cd ~

3. 创建.bash_profile

    输入touch .bash_profile

4. 编辑.bash_profile文件

    输入open -e .bash_profile

    因为是为了搭建Android开发环境,输入Android SDK下的tools目录:export PATH=${PATH}:/eclipse/android_sdk/tools

5. 保存文件,关闭.bash_profile

6. 更新刚配置的环境变量

    输入source .bash_profile

7. 验证配置是否成功

    输入android启动Android SDK and AVD Manager

MAC 上找不到.bash_profile该怎么办?

标签:

原文地址:http://www.cnblogs.com/yk123/p/5819797.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!