Ubuntu 14 配置Android Studio的快捷启动方式
在window7下安装配置了Android Studio之后就想把ubuntu下的Android Studio整舒服。
桌面图标
Ubuntu下解压Android Studio压缩包后有个名为"Install-Linux-tar.txt"的说明文件,里面有这么一段:
Unpack the Android Studio distribution archive that you downloaded to
where you wish to install the program. We will refer to this destination
location as your {installation home} below.Open a console and cd into "{installation home}/bin" and type:
./studio.sh
to start the application.
[OPTIONAL] Add the "{installation home}/bin" to your PATH environmental
variable so that you may start Android Studio from any directory.
如果只做前两步的话每次启动Android Studio都要用终端进入Android Studio的文件夹运行"./studio.sh",这是很麻烦的。
第一次和第二次都是不正解。不想看请跳过。
第一次:修改/etc/profile文件,添加"{installation home}/bin"到环境变量。重启系统使其生效。
事实证明不作死就不会死啊...重启以后被卡在了输密码登陆的界面,无限循环输密码吗进不去系统。
解决办法:1.Ctrl+Alt+F1进入命令界面, 2.输入sudo vi /etc/profile还原为修改前的内容, 3.输入:wq保存, 4.输入reboot重启系统[1]。
第二次:修改/etc/environment添加"{installation home}/bin" 到PATH环境变量,此时可以从任意文件夹启动Android Studio了,但是还是要在终端里面。
顺便profile和environment的区别:系统是先执行/etc/environment,后执行/etc/profile。/etc/environment是设置整个系统的环境,而/etc/profile是设置所有用户的环境。系统应用程序的执行与用户环境可以是无关的,但与系统环境是相关的[2]。
正解在这里!
Google到一篇名为How to add Android Studio to the launcher?的文章[3],里面有一段Answers内容为:
Here is my AndroidStudio .desktop file which works from the launcher.
[Desktop Entry]
Version=1.0
Type=Application
Name=Android Studio
Exec="/home/username/Programs/AndroidStudio/bin/studio.sh" %f
Icon=/home/username/Programs/AndroidStudio/bin/idea.png
Categories=Development;IDE;
Terminal=false
StartupNotify=true
StartupWMClass=jetbrains-android-studio
Name[en_GB]=android-studio.desktop
Alternatively, you can also open Android Studio, click on Configure(如果已经打开了AS,此处就改为Tools) -> Create Desktop Entry. This should create an entry on the dash:
------------------------
AndroidStudio.desktop文件放桌面上,就是下面这样子。
做了这些之后就可以从桌上和dash里启动Android Studio了。
如果提示未信任的应用启动器的问题,这时只要右键该应用的desktop文件,单击属性,在权限选项卡中勾选“允许作为程序执行文件”即可[4]。
锁定到Launcher
参考:
- Ubuntu 14.04解决登录界面无限循环的方法
- linux中/etc/profile 与/etc/environment文件的区别
- How to add Android Studio to the launcher?
- 解决ubuntu下提示未信任的应用启动器的问题
原文地址: http://blog.csdn.net/aaa111/article/details/41833179
Ubuntu 14 配置Android Studio的快捷启动方式相关推荐
- 在Ubuntu环境 下载Android studio,并配置genymotion模拟器(超详细)
Android studio 1. Ubuntu下安装Android studio完整版 1.1. 安装Android studio 1.1.1. 下载环境 1.1.2. 配置共享文件夹 1.1.3. ...
- 【转载】Ubuntu环境下配置Android Studio
之前学习Android开发的时候,一直跟各种教程一样,使用的是Eclipse+ADT,主要是比较方便,容易上手,特别是对于习惯用Eclipse开发java的朋友来说,上手更是好无压力.但毕竟Eclip ...
- Ubuntu下创建Android Studio启动图标
Ubuntu下创建Android Studio启动图标 问题 解决方法1 解决方法2 脚本 问题 Linux发行版的Android Studio没有启动图标 解决方法1 第一次通过终端启动bin/st ...
- android启动windows7,WIN7 32位系统里安装和配置 Android Studio - 20130604
用户评价: / 30 差好 最后更新于 2013年6月04日 点击数:34627 菜鸟日记1-20130604 : 如何在没有安装过JAVA的WIN7 32位系统里安装和配置 Android Stu ...
- 在 Ubuntu 上安装 Android Studio
在 Ubuntu 上安装 Android Studio http://www.linuxidc.com/Linux/2013-05/84812.htm 打开terminal,输入以下命令 sudo a ...
- 安装配置Android Studio集成开发环境
文章目录 一.Android Studio概述 二.下载Android Studio 三.安装Android Studio (一)进入安装向导 (二)选择安装组件 (三)选择安装位置 (四)选择开始菜 ...
- Ubuntu下安装Android Studio
一.系统环境 系统环境 二.安装源文件 Android Studio 3.2.0: android-studio-ide-181.5014246-linux.zip Java SE Developme ...
- 安装和配置 Android Studio
如觉内容冗长,请在页面内再次搜索关键词,定位所需内容. 一.配置好JDK,即java环境. 1.JDK下载 可以直接使用安装Android Studio后内置的jre.然而内置的jre版本较高(1.1 ...
- Android Studio 第一次安装启动Failed to resolve报错解决方案
笔者近期准备着手做一个有关安卓的项目,兴冲冲地找来Android学习书籍,并下载安装了Android Studio.可是在Android Studio的第一次运行就遇到了很大的问题,各种莫名其妙的报错 ...
最新文章
- com.sun.org.apache.xerces.internal.impl.io.MalformedByteSequenceException: 1 字节的 UTF-8 序列的字节 1 无效。
- CentOS 7 使用iptables 开放端口
- FACEBOOK’S CALIBRA
- Unity3D 游戏引擎之IOS高级界面发送消息与Unity3D消息的接收(九)
- 定时创建oracle索引,oracle数据库关于索引建立及使用的详细介绍
- 麟龙指标通达信指标公式源码_通达信指标公式源码单阳不破主图指标公式
- 如何有效的在 LINQ 查询中处理异常?
- Pro*c使用指示变量来处理NULL列值
- iOS25个性能优化,和内存优化
- 一个进程在执行过程中可以被中断事件打断_Linux操作系统:中断类型和中断的作用...
- ServiceStack.Ormlit 使用Insert的时候自增列不会被赋值
- linux 默认文件属性,linux - 文件夹、文件默认属性: umask使用
- AngularJS简单例子
- CMDB内功心法,助我登上运维之巅
- Java核心技术卷一基础知识-第3章-Java的基本程序设计结构-读书笔记
- LEWITT莱维特STREAM4x5、DGT260声卡安装调试教程
- ANSYS ICEM CFD非结构体网格生成实例——换热器
- 疫情持续两年多职场妈妈更努力存钱,近六成中国内地受访者储蓄可维持生活一年以上...
- iOS笔试知识点集锦
- 外研在线:如何用云技术优化教育服务