build.gradle 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. apply plugin: 'com.android.application'
  2. apply plugin: 'com.huawei.agconnect'
  3. android {
  4. compileSdkVersion 29
  5. buildToolsVersion "29.0.3"
  6. defaultConfig {
  7. applicationId "com.anji.plus.pushdemo"
  8. minSdkVersion 21
  9. targetSdkVersion 29
  10. versionCode 1
  11. versionName "1.0.0"
  12. testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  13. flavorDimensions "versionCode"
  14. //统一配置
  15. manifestPlaceholders = [
  16. "JPUSH_PKGNAME" : applicationId,
  17. "JPUSH_APPKEY" : "66c9266fc53b8025cb0dd919", //极光开发平台上注册的包名对应的appkey.
  18. "JPUSH_CHANNEL" : "developer-default", //暂时填写默认值即可.
  19. "appspHost" : "https://openappsp.anji-plus.com",//push请求的host
  20. "appspAppKey" : "3fffc7ab4e704965b3d7ebc034addef7",//为移动服务平台申请的appkey
  21. "appspSecretKey": "12d606b4ab5b496992c48048e2a035f1",//为移动服务平台申请的appspSecretKey
  22. "vivoAppId" : "105303997",//vivo 厂商通道 appID
  23. "vivoAppKey" : "ecaa359c8bbe601d7bbc86d29f5cc58e",//vivo 厂商通道 appKey
  24. "xmAppId" : "\\ 2882303761518880022",//小米 厂商通道 appID,记得如果是长数,前面加“\\ ”,有空格
  25. "xmAppKey" : "\\ 5161888025022",//小米 厂商通道 appKey,记得如果是长数,前面加“\\ ”,有空格
  26. "oppoAppKey" : "c160669462604212962064ffa2df36af",//oppo 厂商通道 appKey
  27. "oppoAppSecret" : "b77b1509f99043e3b695795366e929ef"//oppo 厂商通道 appSecret
  28. ]
  29. }
  30. signingConfigs {
  31. config {
  32. keyAlias 'pushdemo'
  33. keyPassword '123456'
  34. storeFile file('pushDemo.jks')
  35. storePassword '123456'
  36. }
  37. }
  38. buildTypes {
  39. debug {
  40. signingConfig signingConfigs.config
  41. }
  42. release {
  43. signingConfig signingConfigs.config
  44. minifyEnabled false
  45. proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
  46. }
  47. }
  48. }
  49. dependencies {
  50. implementation fileTree(dir: 'libs', include: ['*.jar'])
  51. implementation 'androidx.appcompat:appcompat:1.2.0'
  52. implementation 'com.google.android.material:material:1.2.1'
  53. implementation project(path: ':ajpushlibrary')
  54. testImplementation 'junit:junit:4.+'
  55. androidTestImplementation 'androidx.test.ext:junit:1.1.2'
  56. androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
  57. }