visual-studio-2017tools-for-apache-cordova

android.apk file not being generated in Visual Studio 2017


After upgrading to VS 2017 15.6, when I build my Ionic 1.3 / Cordova project, in "Release" configuration I no longer get a file named android.apk in the bin\Release folder. Instead I am getting a file named VSBuildInfo.xml.

I used to use the android.apk to deploy to my device. How do I do that now?


Solution

  • Something has changed and it's now working as long as I select "Device" as the target.

    I don't remember having to select "Device" as the target when building in previous versions and I was pretty sure that when I was building in "Release" configuration that I did have it selected as the target - but I could be wrong about that.

    One thing I did do was connect a device and click "Deploy" instead of "Build". So it is possible that doing that triggered something that made it start working. This could be a red herring, because it is now working consistently.

    If I select "Simulate..." instead of "Device" as the target, then I get a VSBuildInfo.xml file instead of an apk, as described in my question.