【问题标题】:Sign custom buildtype with a generic debug keystore使用通用调试密钥库签署自定义构建类型
【发布时间】:2019-05-10 09:42:53
【问题描述】:

是否可以创建自定义构建类型并使用调试的密钥库对其进行签名?

buildTypes {
    release {
        minifyEnabled true
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }

    debug {
        debuggable true
        // debug specific configs here
    }

    staging {
        // staging specific configs here
    }
}

我尝试设置 debubbable true 进行暂存,但没有成功。我不能使用initWith 配置,因为debug 配置可能会干扰我的staging 配置。我知道我可以创建一个signingConfig,但这涉及创建一个单独的密钥。我正在考虑使用调试的默认密钥库。

请帮忙。

【问题讨论】:

    标签: android android-gradle-plugin android-keystore android-build-type


    【解决方案1】:

    你可以试试这个:

    staging {
        signingConfig signingConfigs.debug
        ...
    }
    

    【讨论】:

    • 你太棒了!
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2020-06-29
    • 1970-01-01
    • 2017-05-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多