user4414636
user4414636

Reputation:

How to install the development version of the app without removing the published version?

I've made quite a few changes to my app, and I want to see if there are any crashes if the users update my app to the new version from the previous version. I want download my app from play store, perform some actions, and then update it to the development version, but when I try to do so, Android Studio promopts me to uninstall the old version first. Is there a way I can update over the old version, just like my users would, if I published an update?

Upvotes: 0

Views: 180

Answers (1)

CommonsWare
CommonsWare

Reputation: 1006914

android {
  // other stuff here

  buildTypes {
    debug {
      applicationIdSuffix '.debug'
    }
  }
}

This will give your debug builds a distinct application ID, allowing you to have the debug and release builds installed at the same time.

Note, though, that otherwise the two apps will be identical in all other respects by default, meaning that you will have two identical launcher icons. To distinguish between those, you might consider adding app/src/debug/res/values/string.xml and have a debug definition of the app_name string resource, so your launcher icons will have different captions. Note that this recipe assumes that you have a conventional Android Studio project (app/ module, with the manifest using @string/app_name for relevant android:label attributes).

Upvotes: 1

Related Questions