Google Play商店-如何使用不同的软件包名称推广测试应用? [英] google play store - how to promote test app with different package name?

查看:286
本文介绍了Google Play商店-如何使用不同的软件包名称推广测试应用?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是关于android中包名称的问题.我目前在gradle中有两种构建风格.生产和分期.

This is a question about package names in android. I currently have two build flavors in gradle. Production and Staging.

我已经创建了一个Google Play商店帐户,我希望用户对我的应用进行Alpha和Beta测试.目前,该登台应用程序的软件包名称为: com.mobile.myapp.staging,而生产风味的包名称为com.mobile.myapp.

I have created a google play store account and i want users to alpha and beta test my app. The staging app currenly has a package name of: com.mobile.myapp.staging while the production flavor has a package name of com.mobile.myapp.

所以我们有

com.mobile.myapp.staging vs com.mobile.myapp

最后,我显然想将com.mobile.myapp推广到生产环境,而不是将其升级.但我希望用户长时间使用暂存变体进行测试(因为它已连接至暂存api等).

in the end i clearly want to promote com.mobile.myapp to production not the staging. but i'd like the users to test with the staging variant for a long while (as its connected to staging apis . etc etc.)

我该怎么做?我需要在Google Play商店中创建两个不同的应用程序吗?我想知道我是否必须这样做 它们都有不同的程序包名称.它们都将使用相同的密钥库进行签名.请帮忙.

How can i do this ? would i have to create two different apps in the google play store ? I am wondering if i have to do this as they both have different package names. They both will be signed with the same keystore. Please help.

我的gradle文件看起来像这样:

my gradle file looks like this:

apply plugin: 'com.android.application'

android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
minSdkVersion project.ext.minimumSdkVersion
//check top level build.gradle  file for attributes -
targetSdkVersion 25
applicationId "com.mobile.myapp"
versionCode 150010203
versionName 1.2.3 
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"

//renderscriptTargetApi 25
//renderscriptSupportModeEnabled true
multiDexEnabled true
}
buildTypes {
release {
    minifyEnabled false
    proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}

dexOptions {
javaMaxHeapSize "6g"
}//for out of memory gc overhead error
lintOptions {
abortOnError false
}

productFlavors {

def STRING = "String"
def BOOLEAN = "boolean"
def TRUE = "true"
def FALSE = "false"
def FLAVOR = "FLAVOR"
def RETROFIT_LOG_ALL = "RETROFIT_LOG_ALL"
def BASE_ENDPOINT = "BASE_ENDPOINT"

staging {
    // applicationId "com.mobile.myapp.staging"
    buildConfigField STRING, BASE_ENDPOINT, '"https://api.flyingSaucerxx-staging.com"'
    buildConfigField BOOLEAN, RETROFIT_LOG_ALL, TRUE
    manifestPlaceholders = [appDrawerName: "FlyingSaucer-Staging"]
    applicationIdSuffix '.staging'
    versionNameSuffix '-STAGING'
}

prod {
    buildConfigField STRING, BASE_ENDPOINT, '"https://api.flyingSaucerxx.com"'
    buildConfigField BOOLEAN, RETROFIT_LOG_ALL, FALSE
    manifestPlaceholders = [appDrawerName: "FlyingSaucer"]
}
}
}

///.. dependencies below

推荐答案

对于同一应用程序,无法在Google Play商店中使用不同的程序包名称.

It is not possible to use different package names in Google Play Store for the same app.

因此,您唯一的选择是将登台应用程序的程序包名称更改为生产版本.并将其提交给alpha/beta测试人员.并且一定要当心不要将其推广到生产中.

So the only option you have is to change package name of your staging app to production one. And submit it to alpha/beta testers. And sure watch out to not promote it to production.

另一种选择是使用其他传递渠道,例如hockeyapp或crashlitics beta.

Another option is to use other delivery channels like hockeyapp or crashlitics beta.

这篇关于Google Play商店-如何使用不同的软件包名称推广测试应用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆