java 找不到 studio.sh 命令 - Ubuntu

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/35572804/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-11-03 00:18:02  来源:igfitidea点击:

studio.sh command not found - Ubuntu

javaandroidubuntuandroid-studio

提问by Anshu Dutta

I am trying to get Android Studio running. I have installed jdk and jre

我正在尝试让 Android Studio 运行。我已经安装了 jdk 和 jre

sudo apt-get install default-jre
sudo apt-get install default-jdk

I have set up my .bashrc and /etc/environmentfile to

我已经将我的 .bashrc 和/etc/environment文件设置为

export JAVA_HOME=/usr/lib/jvm/java-1.7.0-openjdk-amd64
export PATH=$JAVA_HOME/bin:$PATH

but still nothing.

但仍然没有。

$JAVA_HOMEreturns correct value and so do java -versionand whereis javac

$JAVA_HOME返回正确的值,所以这样做java -version和 whereis javac

What am I missing?

我错过了什么?

回答by N J

Following step worked for me

以下步骤对我有用

  1. cd to YOUR_DIR_WHERE_ANDROID_STUDIO_TILL_BIN_FOLDER
  2. then type command sh studio.shor ./studio.sh
  1. cd 到YOUR_DIR_WHERE_ANDROID_STUDIO_TILL_BIN_FOLDER
  2. 然后输入命令sh studio.sh./studio.sh

回答by Araali Farooq

Try using sh ./studio.shinstead. Good luck.

尝试使用sh ./studio.sh代替。祝你好运。

回答by Yog

It worked for me -> Go to directory that has android studio bin.

它对我有用-> 转到具有 android studio bin 的目录。

-> Instead of using studio.sh use the command sh studio.shenter image description here

-> 使用命令sh studio.sh而不是使用studio.sh在此处输入图片说明