How do you manage multiple environments while developing Android apps?

前端 未结 6 618
温柔的废话
温柔的废话 2020-12-22 23:04

We\'re building an Android app that connects to the cloud. We have a test URL for our APIs and a production URL. We connect the app to our local development machines to talk

6条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-22 23:45

    You can try gradle buildType and productFlavor. It will allow you to specifiy different Environment variables like url, versionName, etc And applicationId which will allow you to have dev and prod builds. For more details http://developer.android.com/tools/building/configuring-gradle.html

提交回复
热议问题