Creating an app with PhoneGap Build – Part 5: Publishing to Google Play
This is the fifth part in a blog series detailing creating the TRINUG Android app via PhoneGap Build. In this post, I share my experiance publishing the app to the Google Play Android store.
The TRINUG app I created details upcoming event info for my local .NET user group. So why did I decide to first release my app via Google Play? There are many reasons, but it boils down to it being the fastest, simplest, and cheapest way to distribute an app compared to iOS and Windows Phone. Plus, Android as a whole (meaning all versions) makes up the largest market share of smart phone operating systems.
Both iOS and WP7 have an annual $99 fee they charge to developers for the privilege of being able to publish apps to their marketplaces. They both also have an app submission approval process. Android on the other hand charges a one-time $25 fee for a Google Play publisher account. There is no formal approval process for releasing apps and app updates on Google Play.
Preparation for Publishing
Android has a very easy to read Publishing Checklist for Google Play guide. Even though an app developed via PhoneGap Build isn’t a ‘true ‘ native Android app, it still must meet certain Android-specific guidelines in order for the install to be uploaded to the Google Play store.
There are currently 16 checklist items Google provides for publishing preparation. For the TRINUG app, I was only really concerned with two of the items. One was item 11: ‘Prepare Promotional Graphics’. When you upload your app to the Google Play publishing site, besides your installable .apk file, you’ll be asked to provide some additional graphics. The detailed requirements are listed here. The first requirement is at least two screenshots.
Getting a screenshot of your app running on your Android device is something that will require a 3rd party app to do. Unlike iOS, there are no shortcut button combinations to capture a screenshot. There are several Android screenshot apps available but some require your phone to be rooted. My phone (a Samsung Galaxy S 4G) is not rooted. I ended up choosing the Screenshot UX app and was very pleased with the results.
The other graphic requirement is a high-resolution application icon. The reason for this is it provides a way for Google Play to show a large-sized icon on your app’s Google Play page. I am not a graphic designer by any sort of the imagination and this requirement had me a bit worried. Fortunately, there are free online tools to generate Android-sized icons for you. The one I used was Android Asset Studio.
Preparing the APK
The Android Publiching Checklist mentioned above has one other very important item: #12 ‘Build and upload the release-ready APK’. It includes a link to an article detailing the process. There are two main items here that you need to pay attention to. The first being that your app can’t be in Debug mode. If you remember, PhoneGap Build has an option to create a Debug build. Make sure that option is turned off in PhoneGap Build for the apk file you create for the Google Play. The second thing you’ll need to do is sign your apk. I’ll detail that process below.
Creating a Google Play Publisher Account
Creating a Google Play publisher account is very simple. Just navigate to the Developer Console and sign in with your Google account. You’ll be walked through a series of steps and will purchase a developer account for $25. Once that is complete, you’ll be brought to the Developer Console where your apps are managed.
Signing Your App
Signing your app is detailed in the Google Play developer documentation here. This step had me a bit perplexed because the documentation refers to Java, Eclipse, Keytool, and tools that I was uncomfortable or unfamiliar with. The bottom like is this: you need to install the latest version of Java from Oracle. Once you do that, you’ll need to open a command prompt and follow some steps to generate a key for your application. I followed the instructions from this DreamWeaver site on how to do all that.
Once your you create the key and password as detailed in that article, it has to be uploaded to PhoneGap Build. The place to do that is Edit-> Signing. You’ll be presented this screen where you’ll upload your key and enter in the key’s password that you created with the keytool.
With your key in place, rebuild your app in PhoneGap Build and download the apk on to your computer. It’s now time to publish it to Google Play.
Publishing on Google Play
The Google Play Developer Console is an intuitive series of screens where you’ll be asked to upload your apk, graphic assets, and answer questions about your app like the description, category, content rating, etc. The information you provide basically provides a way for someone to find your application from within Google Play.
That is pretty much it! Once you fill in all the required fields in the Developer Console for your application, you’ll be able to publish it. I published TRINUG late at night and waited around for about 30 minutes but didn’t see it in the Google Play store. The next morning it was there. I’ve since pushed an update out for the app and found it took about an hour for the changes to propagate in to the Google Play store.
In the final article of this series, I’ll provide a summary of my thoughts regarding the use of PhoneGap Build including lessons learned.