Android Studio不会将更改部署到应用程序 [英] Android Studio not deploying changes to app

查看:215
本文介绍了Android Studio不会将更改部署到应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有时这种情况发生在开发中。我将修改源代码,点击保存全部然后运行,但更改显然不会在应用程序中反映 - (我正在使用设备进行测试)。我甚至可以卸载我的设备上的应用程序,再次点击运行,新安装的应用程序仍然没有反映源代码的变化。当这种情况发生时,我必须编辑源代码,点击运行,也可能是一个新的版本,我预期的更改将在设备上。

Sometimes this scenario occurs when developing. I would make a change in my source code, hit save all and then run but the change wouldn't be apparently not reflected in the app -(I'm using a device for testing). I can even uninstall the app on my device, and hit run again and the newly installed app still hasn't reflected the change in the source code. When this happens I have to edit the source, hit run and maybe then a new version with the changes I expected will be on the device.

我也在这里尝试了解决方案,但似乎并不常用。

I also tried the solution here, but it doesn't seem to work often.

Android Studio - 部署我的应用程序,不需要新的更改

推荐答案

我有同样的问题。当我搜索它时,这个线程首先弹出。通过不使用即时运行功能来解决它​​(希望如此)。可能不是最好的解决方案,但它现在可以工作。

I've got the same problem. This thread popped up first when I've searched for it. Solved it (hoping so) by not using the Instant Run feature. Might not be the best solution but it works for now.

只需转到文件 - >设置 - >构建,执行,部署 - >即时运行,然后禁用它。这个Android Studio每次都是从头开始构建的,但它比没有正确构建更好。

Just go to "File -> Settings -> Build, Execution, Deployement -> Instant Run" and just disable it. With this Android Studio builds from scratch each time but it's better than not building it right.

迷你咆哮:几乎每个版本的Android Studio都带来了一个烦人的错误。他们即将发布版本2,但它的beta仍然是错误的。我希望他们能够在不久的将来稳定IDE。

Mini rant: Almost each version of Android Studio comes with an annoying bug. They're about to release the version 2 but its beta is still buggy. I hope they stabilize the IDE in the near future.

这篇关于Android Studio不会将更改部署到应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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