增加极光推送
This commit is contained in:
@@ -51,8 +51,37 @@ android {
|
||||
enabled true
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
jniLibs.srcDir(['libs'])
|
||||
}
|
||||
}
|
||||
|
||||
repositories {
|
||||
flatDir {
|
||||
dirs 'libs'
|
||||
}
|
||||
}
|
||||
|
||||
buildConfigField "String", "QweatherId", "\"${qweatherConfigs.credential.id}\""
|
||||
buildConfigField "String", "QweatherKey", "\"${qweatherConfigs.credential.key}\""
|
||||
|
||||
manifestPlaceholders = [
|
||||
JPUSH_PKGNAME : applicationId,
|
||||
JPUSH_APPKEY : "d779178d9900d4fb5d633678", //JPush 上注册的包名对应的 Appkey.
|
||||
JPUSH_CHANNEL : "developer-default", //暂时填写默认值即可.
|
||||
MEIZU_APPKEY : "MZ-魅族的APPKEY",
|
||||
MEIZU_APPID : "MZ-魅族的APPID",
|
||||
XIAOMI_APPID : "小米的APPID",//JPush5.5.3开始,可以不添加MI-前缀.
|
||||
XIAOMI_APPKEY : "小米的APPKEY",//JPush5.5.3开始,可以不添加MI-前缀.
|
||||
OPPO_APPKEY : "OP-oppo的APPKEY",
|
||||
OPPO_APPID : "OP-oppo的APPID",
|
||||
OPPO_APPSECRET: "OP-oppo的APPSECRET",
|
||||
VIVO_APPKEY : "vivo的APPKEY",
|
||||
VIVO_APPID : "vivo的APPID",
|
||||
HONOR_APPID : "honor的APPID",
|
||||
NIO_APPID : "nio的APPID"
|
||||
]
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
@@ -69,9 +98,27 @@ android {
|
||||
keyAlias rootProject.ext.signingConfigs.crosshatch.keyAlias
|
||||
keyPassword rootProject.ext.signingConfigs.crosshatch.keyPassword
|
||||
}
|
||||
|
||||
zhanxun {
|
||||
storeFile file(rootProject.ext.signingConfigs.zhanxun.storeFile)
|
||||
storePassword rootProject.ext.signingConfigs.zhanxun.storePassword
|
||||
keyAlias rootProject.ext.signingConfigs.zhanxun.keyAlias
|
||||
keyPassword rootProject.ext.signingConfigs.zhanxun.keyPassword
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
zhanRuiDebug.initWith(debug)
|
||||
zhanRuiDebug {
|
||||
debuggable true
|
||||
signingConfig signingConfigs.zhanxun
|
||||
}
|
||||
|
||||
zhanRuiRelease.initWith(release)
|
||||
zhanRuiRelease {
|
||||
signingConfig signingConfigs.zhanxun
|
||||
}
|
||||
|
||||
CrosshatchDebug.initWith(debug)
|
||||
CrosshatchDebug {
|
||||
debuggable true
|
||||
@@ -82,6 +129,7 @@ android {
|
||||
CrosshatchRelease {
|
||||
signingConfig signingConfigs.crosshatch
|
||||
}
|
||||
|
||||
debug {
|
||||
versionNameSuffix "_debug"
|
||||
debuggable true
|
||||
@@ -122,6 +170,10 @@ android {
|
||||
|
||||
}
|
||||
|
||||
ext {
|
||||
jpush = [version: "5.7.0"]
|
||||
}
|
||||
|
||||
dependencies {
|
||||
// implementation fileTree(dir: 'libs', include: ['*.jar'])
|
||||
//Android 4.4+
|
||||
@@ -192,16 +244,59 @@ dependencies {
|
||||
//bugly
|
||||
implementation 'com.tencent.bugly:crashreport:4.1.9.3'
|
||||
implementation 'com.iqiyi.xcrash:xcrash-android-lib:3.0.0'
|
||||
|
||||
// 替换成最新版本, 需要注意的是api
|
||||
// 要与compiler匹配使用,均使用最新版可以保证兼容
|
||||
implementation 'com.alibaba:arouter-api:1.5.2'
|
||||
annotationProcessor 'com.alibaba:arouter-compiler:1.5.2'
|
||||
|
||||
//推送
|
||||
//阿里云
|
||||
implementation 'com.aliyun.ams:alicloud-android-push:3.9.3'
|
||||
//极光
|
||||
// 此处以JPush 5.6.0 版本为例,注意:从 5.0.0 版本开始可以自动拉取 JCore 包,无需另外配置
|
||||
implementation "cn.jiguang.sdk:jpush:$jpush.version"
|
||||
//若不集成厂商通道,可直接跳过以下依赖
|
||||
// 极光厂商插件版本与接入 JPush 版本保持一致,下同
|
||||
// 接入华为厂商
|
||||
implementation 'com.huawei.hms:push:6.13.0.300'
|
||||
implementation "cn.jiguang.sdk.plugin:huawei:$jpush.version"
|
||||
// 接入 FCM 厂商
|
||||
implementation 'com.google.firebase:firebase-messaging:24.1.0'
|
||||
implementation "cn.jiguang.sdk.plugin:fcm:$jpush.version"
|
||||
// 接入魅族厂商
|
||||
implementation "cn.jiguang.sdk.plugin:meizu:$jpush.version"
|
||||
// JPush Android SDK v5.2.3 开始,需要单独引入 魅族 厂商 aar ,请下载官网 SDK 包并把 jpush-android-xxx-release/third-push/meizu/libs 下的 aar 文件单独拷贝一份到应用 module/libs 下
|
||||
implementation(name: 'push-internal-5.0.5', ext: 'aar')
|
||||
// 接入 VIVO 厂商
|
||||
implementation "cn.jiguang.sdk.plugin:vivo:$jpush.version"
|
||||
// 接入小米厂商
|
||||
implementation "cn.jiguang.sdk.plugin:xiaomi:$jpush.version"
|
||||
// 接入 OPPO 厂商
|
||||
implementation "cn.jiguang.sdk.plugin:oppo:$jpush.version"
|
||||
// JPush Android SDK v4.6.0 开始,需要单独引入 oppo 厂商 aar ,请下载官网 SDK 包并把 jpush-android-xxx-release/third-push/oppo/libs 下的 aar 文件单独拷贝一份到应用 module/libs 下
|
||||
implementation(name: 'com.heytap.msp_V3.7.1', ext: 'aar')
|
||||
//以下为 OPPO 3.1.0 aar需要依赖
|
||||
implementation 'com.google.code.gson:gson:2.10.1'
|
||||
implementation 'commons-codec:commons-codec:1.6'
|
||||
implementation 'androidx.annotation:annotation:1.1.0'
|
||||
// 接入荣耀厂商
|
||||
implementation "cn.jiguang.sdk.plugin:honor:$jpush.version"
|
||||
//需要单独引入荣耀厂商 aar ,请下载官网 SDK 包并把 jpush-android-xxx-release/third-push/honor/libs 下的 aar 文件单独拷贝一份到应用 module/libs 下
|
||||
implementation(name: 'HiPushSDK-8.0.12.307', ext: 'aar')
|
||||
// 接入蔚来厂商
|
||||
implementation "cn.jiguang.sdk.plugin:nio:$jpush.version"
|
||||
//JPush Android SDK v5.6.0 开始需要单独引入蔚来厂商 aar ,请下载官网 SDK 包并把 jpush-android-xxx-release/third-push/nio/libs 下的 aar 文件单独拷贝一份到应用 module/libs 下
|
||||
implementation(name: 'niopush-sdk-v1.0', ext: 'aar')
|
||||
|
||||
|
||||
//地图组件
|
||||
implementation 'com.baidu.lbsyun:BaiduMapSDK_Map:7.6.4'
|
||||
//基础定位组件
|
||||
implementation 'com.baidu.lbsyun:BaiduMapSDK_Location:9.6.4'
|
||||
//全量定位组件
|
||||
// implementation 'com.baidu.lbsyun:BaiduMapSDK_Location_All:9.6.4'
|
||||
|
||||
//TTS组件
|
||||
implementation 'com.baidu.lbsyun:NaviTts:3.2.13'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user