开发者

android maven automation

U开发者_如何学JAVAsing the maven android eclipse plugin, is it possible to have a maven configuration that automatically launches the android project (the app) in debug mode, so that eclipse automatically attaches to that process ?

Thanks.


There is currently no feature to launch/run the app from the Maven Android Plugin. There is a feature request to do just that

http://code.google.com/p/maven-android-plugin/issues/detail?id=102

and it would be fairly easy to do. I have not had the chance to do it yet. Feel free to implement it as a standalone mojo and submit a pull request. I can definitely pull it in for the 3.0 release.

One thing that is happening though is when you run the instrumentation tests the apk will be deployed as well as the test and a new setting in the testing code allows for waiting for a debugger to connect..

Update:

There is now a run goal that will run your main activity set as launcher in your AndroidManifest and run the application on all connected devices and emulators.


Part of what the maven android eclipse plugin does is get your eclipse project setup properly (Build path, etc). If this is done properly, using eclipse to launch the app in debug mode is the best move. So you would right click your android project, Debug As, Android Application.

Just because you're using maven doesn't mean every action (especially IDE actions) has to go through a maven command.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜