Reputation: 5993
Is there a way to force Eclipse to restart an Android app that has not changed, even if it has to be re-downloaded and reinstalled?
I am in a situation where I'm running an Android app that does stuff on startup that I need to repeat for debugging purposes.
What I would like to do is click the "Run" button in Eclipse and have it force restart my app each time. But instead, Eclipse/Android tries to be smart and it just brings my app to the front without restarting. I get a message in the console:
ActivityManager: Warning: Activity not started, its current task has been brought to the front
The only workaround I have found is to make dummy text changes to force a recompile/re-install. But that's kind of annoying, especially with the code under revision control.
Upvotes: 9
Views: 1850
Reputation: 8935
Besides already mentioned meaningless chars and stopping from device menu, you can also stop your application process from DDMS perspective, Devices View -> Name of your process -> push red button.
Upvotes: 6
Reputation: 9300
The lazy work is to put a space char , save it, delete the char, save it and rebuild. As i said the lazy (fast) work..
Upvotes: 6
Reputation: 5759
Kill the app from the running tasks either on the emulator or on the device you are debugging on.
Upvotes: 1