I have a minor issue with the way IntelliJ caches files or builds (not sure about terminology here).

我对IntelliJ缓存文件或构建的方式有一个小问题(这里不确定术语)。

Situation Abstract:

情况摘要:

Library module

图书馆模块

  • DrawableA
  • DrawableA
  • DrawableB
  • DrawableB

App module

应用模块

  • DrawableA
  • DrawableA

Assume library images are black and white, App ones are color.
The app shows (correctly) the colorful A.
The app shows (correctly) the black and white B (means its missing).
Now I add an image to App project, Drawable B, in color.

假设库图像是黑白的,应用程序图像是彩色的。该应用程序显示(正确)丰富多彩的A.该应用程序显示(正确)黑色和白色B(意味着它缺少)。现在我将图像添加到App项目,Drawable B,颜色。

  • If you simply press "run" he will keep using black and white B
  • 如果你只是按“运行”,他将继续使用黑色和白色B.
  • If you "rebuild project" he will use the correct one
  • 如果你“重建项目”,他将使用正确的项目
  • If you try "Make" and "Compile" manually on Lib and App NO EFFECT
  • 如果您在Lib和App NO EFFECT上手动尝试“Make”和“Compile”

To clarify, this issue is really special. It only occurs if the DrawableB is NOT present in the App module. If you have it, but the WRONG one, and you update it, it works. I assume its an internal caching of IntelliJ, and he does not recognize that I added a drawable (and he has to use it from the App now, not the LIB). Perhaps its something in the google build of Android projects, not enough info about the internal here...

澄清一下,这个问题非常特别。只有在App模块中不存在DrawableB时才会发生这种情况。如果您拥有它,但是错误的,并且您更新它,它可以工作。我假设它是IntelliJ的内部缓存,他不承认我添加了一个drawable(他现在必须从App使用它,而不是LIB)。也许它是谷歌构建的Android项目中的东西,没有关于内部的足够信息在这里......

I know, the obvious tip is "do a rebuild of the whole project" - that said, I have 18 App modules, each for one App. The rebuild takes forever (on one of our machines without SSD), and its not neccessary. If I change something in e.g. AppX, I only need to rebuild AppX and the Library. But there seems to be no option for it.

我知道,明显的提示是“重建整个项目” - 说,我有18个App模块,每个模块用于一个App。重建需要永远(在我们的一台没有SSD的机器上),而且不是必需的。如果我改变一些东西,例如AppX,我只需要重建AppX和库。但似乎没有选择。

Does anyone know a workaround, like deleting BIN or other cache folders via script? Cant split up the modules in different "projects", would loose refactoring capabilities.

有没有人知道一种解决方法,比如通过脚本删除BIN或其他缓存文件夹?不能在不同的“项目”中拆分模块,会失去重构能力。

Crosspost here, check before wasting time to answer (this site here is more frequented and faster, but this issue is so specific, cant hurt to ask the developers too)
http://devnet.jetbrains.net/message/5446674

Crosspost在这里,检查之前浪费时间回答(这里的网站更频繁,更快,但这个问题是如此具体,不能再向开发人员询问了)http://devnet.jetbrains.net/message/5446674

2 个解决方案

#1


3

Try to rebuild project. Smtm i have same problem and it helps me.

尝试重建项目。 Smtm我有同样的问题,它帮助我。

更多相关文章

  1. 使用scala编写Android项目
  2. Android自定义控件——开源组件SlidingMenu的项目集成
  3. Proguard可以对Android库项目(APKLIB)进行模糊处理吗?
  4. 最近一年做Android项目过程中,对其的一些注意事项(优化)以及问题
  5. Android小项目之六 apk下载
  6. Say Hello To Android(解析Android项目目录结构)
  7. linux android 如何把android项目打成jar包
  8. 删除Listview中第一个项目顶部的行
  9. Android功能模块化之网络连接状态判断

随机推荐

  1. android中关于调用super的时机
  2. Android 开发之获取手机中所有App
  3. android > 旋转屏幕时 不重加载 activity
  4. Android编译系统详解(三)
  5. Android获取手机存储空间大小
  6. Android build.gradle 中 使用 buildConf
  7. Android 文件IO总结
  8. Android Studio 3.0以后打包修改文件名方
  9. AndroidManifest.xml【 manifest -> perm
  10. [Android] 环境优化配置Android Studio发