我已经安装了新的Android Studio。一切都工作得很好,但当我试图创建一个新项目时,它在下载Gradle时卡住了。

有没有办法手动安装Android Studio所需的Gradle ?或者有其他方法可以解决这个问题吗?


当前回答

Windows用户

使用您的网络资源监视器

打开任务管理器[Ctrl+Shift+Esc]

性能选项卡

开放资源监视器(从底部开始)

首先,我决定在阅读完这里的答案后等待。但能持续多久?如何确保它能完成?他们应该提供下载百分比,但他们没有。为了了解正在进行的某些进程,打开这个网络资源监视器,它会显示正在下载Studio64.exe。如果不是(如果它显示0B/Sec),那么要么网络不可用,要么应用程序没有响应。

其他回答

解决方案:

1).删除“c:\ users \用户名”gradle文件夹

2).下载http://downloads.gradle.org/distributions/gradle-2.2.1-all.zip

3).在android studio中创建一个新项目。

4).当这个时候它卡在gradle建筑,强制关闭android工作室。

5)现在转到C:\Users\username.gradle\wrapper\dist \gradle-2.2.1-all\c64ydeuardnfqctvr1gm30w53(结束目录名可能不同)

6)删除gradle-2.2.1-all.zip。LCK和该目录下的其他文件。

7)在这里粘贴下载的gradle-2.2.1-all.zip文件。

8)运行android工作室。:)

是的,有。

Create a new project and you should Shutdown The Android Studio Application.(Because it takes a long time for you). Goto C:\Users\{Logged in User}\.gradle folder There is a folder there that show you which version of gradle Android Studio requires (e.g. gradle-1.8-bin) Download this version from internet (e.g. gradle-1.8-bin.zip). Goto C:\Users\{Logged in User}\.gradle\wrapper\dists\gradle-1.8-bin There is a folder here that its name is like a GUID. You should just copy the zip file that you've already downloaded from internet into this folder. Execute Android Studio and create a new project.

Android Studio自带Gradle,但它没有命令行Gradle功能。

对我有用的是:

创建一个虚拟项目,当它卡在Build屏幕上时, 终止studio进程。 打开android studio,打开项目,项目就会崩溃 用已经打开的虚拟项目创建一个新项目,它将毫无问题地创建项目 关闭虚拟项目,享受乐趣

使缓存无效并重新启动

这对我很管用。