android-studio:执行时出错 studio.sh
android-studio : Error while executing studio.sh
参加完Google IO 2016 extended,我从https://dl.google.com/dl/android/studio/ide-zips/2.2.0.0/android-studio-ide-145.2878421-linux.zip
下载了studio
我提取出来了。但在那之后,我无法执行 studio.sh..
显示以下错误:
To-be-filled-by-O-E-M:~/Applications/android-studio/bin$ ./studio.sh
./studio.sh: 137: ./studio.sh: declare: not found
./studio.sh: 141: ./studio.sh: Syntax error: "(" unexpected (expecting "fi")
我是不是漏掉了什么?
注意: 我已将问题发布到 Google Plus 社区 Android Studio. Hers's the Link to my post
只需使用之前的 studio.sh 文件,它的效果非常好!
如果您是 ubuntu 用户,那么您可以编辑 studio.sh 并将第一行从
更改为
#!/bin/sh
到
#!/bin/bash
它在 Ubuntu 14.04 对我有用。
编辑文件~/android-studio/bin/studio.sh
:
更改第 1 行
#!/bin/sh
至
#!/bin/bash
我也遇到了同样的错误,我已经用我以前的 /bin/studio.sh 替换了最新的 /bin/studio.sh 文件 文件,它就像魅力一样。
此问题已在 Android Studio 2.2 预览版 2(从 this page 下载)中修复。
Fixed bug preventing the IDE from starting on some Linux distributions (in particular where /bin/sh is not bash)
来自changelog.
参加完Google IO 2016 extended,我从https://dl.google.com/dl/android/studio/ide-zips/2.2.0.0/android-studio-ide-145.2878421-linux.zip
下载了studio我提取出来了。但在那之后,我无法执行 studio.sh..
显示以下错误:
To-be-filled-by-O-E-M:~/Applications/android-studio/bin$ ./studio.sh
./studio.sh: 137: ./studio.sh: declare: not found
./studio.sh: 141: ./studio.sh: Syntax error: "(" unexpected (expecting "fi")
我是不是漏掉了什么?
注意: 我已将问题发布到 Google Plus 社区 Android Studio. Hers's the Link to my post
只需使用之前的 studio.sh 文件,它的效果非常好!
如果您是 ubuntu 用户,那么您可以编辑 studio.sh 并将第一行从
更改为#!/bin/sh
到
#!/bin/bash
它在 Ubuntu 14.04 对我有用。
编辑文件~/android-studio/bin/studio.sh
:
更改第 1 行
#!/bin/sh
至
#!/bin/bash
我也遇到了同样的错误,我已经用我以前的 /bin/studio.sh 替换了最新的 /bin/studio.sh 文件 文件,它就像魅力一样。
此问题已在 Android Studio 2.2 预览版 2(从 this page 下载)中修复。
Fixed bug preventing the IDE from starting on some Linux distributions (in particular where /bin/sh is not bash)
来自changelog.