Android Studio 很慢 [英] Android Studio is very slow

查看:31
本文介绍了Android Studio 很慢的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个项目,里面有大约 20 个模块.Gradle clean 大约需要 5 分钟.同样,如果我添加一个新模块 gradle 更新项目需要超过 5 分钟.

I have a project with about 20 modules inside. Gradle clean takes about 5min. As ell if i add a new module gradle update projects needs more than 5min.

不依赖于外部库.依赖只存在于项目内部的几个模块之间.

There are no dependencies to external libraries. Dependencies are only inside the project between several modules.

我有没有 gradle 的相同项目,它运行良好.我没有将旧项目转换为 gradle.我用gradle推荐的文件结构创建了一个新项目.但是对于这种性能,这不是很有用...

I had same Project without gradle and it worked fine. I did not convert the old project to gradle. I have created a new project with the file structure recomended by gradle. But with this performance this is not very usefull...

知道 gradle 出了什么问题吗?

Any idea what's going wrong with gradle?

推荐答案

只需在以下目录中创建一个名为 gradle.properties 的文件:

Just create a file named gradle.properties in the following directory:

/home/<username>/.gradle/ (Linux)
/Users/<username>/.gradle/ (Mac)
C:Users<username>.gradle (Windows)

将此行添加到文件中:

org.gradle.daemon=true

来源:https://www.timroes.de/2013/09/12/speed-up-gradle/

这篇关于Android Studio 很慢的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆