build.gradle
4.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
plugins {
id 'com.android.application'
id 'io.objectbox'
}
android {
compileSdkVersion 29
buildToolsVersion "30.0.3"
defaultConfig {
applicationId "com.whaty.nafmii"
minSdkVersion 24
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
buildConfigField "String", "API_HOST", "\"http://10.10.81.189/nafmii/app/\""
buildConfigField "String", "IMG_API", "\"http://10.10.81.172/group1/\""
buildConfigField "String", "WX_APPID", "\"1234567890\""
buildConfigField "boolean", "SHOW_INPUT", "true"
ndk {
abiFilters "armeabi", "armeabi-v7a", "x86", "mips"
}
javaCompileOptions {
annotationProcessorOptions {
arguments = [
"objectbox.modelPath" : "$projectDir\\schemas\\objectbox.json".toString(),
"objectbox.myObjectBoxPackage": "com.polysoft.nafmii.database"
]
}
}
manifestPlaceholders = [
JPUSH_PKGNAME : applicationId,
JPUSH_APPKEY : "ef86f246857d981193987dee",//值来自开发者平台取得的AppKey
JPUSH_CHANNEL : "default_developer",
//meizu_config_start
// MEIZU_APPKEY : "MZ-魅族的APPKEY",
// MEIZU_APPID : "MZ-魅族的APPID",
//meizu_config_end
//xiaomi_config_start
XIAOMI_APPID : "MI-小米的APPID",
XIAOMI_APPKEY : "MI-小米的APPKEY",
//xiaomi_config_end
//oppo_config_start
// OPPO_APPKEY : "OP-oppo的APPKEY",
// OPPO_APPID : "OP-oppo的APPID",
// OPPO_APPSECRET: "OP-oppo的APPSECRET",
// //oppo_config_end
// //vivo_config_start
// VIVO_APPKEY : "vivo的APPKEY",
// VIVO_APPID : "vivo的APPID",
//vivo_config_end
]
}
buildTypes {
release {
minifyEnabled true //是否混淆
zipAlignEnabled true //是否设置zip对齐优化
shrinkResources true // 移除无用的resource文件
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
buildConfigField "boolean", "SHOW_INPUT", "false"
}
pro { // 模拟
resValue "string", "app_name", "Nafmii-pro"
applicationIdSuffix "pro"
}
uat { // 测试
resValue "string", "app_name", "Nafmii-uat"
applicationIdSuffix "uat"
}
debug {
minifyEnabled false
resValue "string", "app_name", "Nafmii-dev"
applicationIdSuffix "dev"
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
signingConfigs {
debug {
storeFile file('D:\\studio-workspace\\nafmii\\nafmii.keystore')
storePassword 'whaty123'
keyPassword 'whaty123'
keyAlias 'whaty'
}
}
ndkVersion '20.0.5594570'
}
dependencies {
implementation 'androidx.wear:wear:1.0.0'
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'com.google.android.material:material:1.2.1'
implementation 'androidx.constraintlayout:constraintlayout:2.0.1'
implementation 'ren.yale.android:cachewebviewlib:2.1.8'
implementation 'com.alibaba:fastjson:1.2.75'
implementation 'com.wang.avi:library:2.1.3'
implementation 'com.tencent.mm.opensdk:wechat-sdk-android-without-mta:6.7.0'
implementation 'com.squareup.okhttp3:okhttp:5.0.0-alpha.2'
implementation 'com.github.bumptech.glide:glide:4.12.0'
implementation 'org.greenrobot:eventbus:3.2.0'
implementation 'cn.jiguang.sdk:jpush:4.3.0' // 此处以JPush 4.3.0 版本为例。
implementation 'cn.jiguang.sdk:jcore:2.9.0' // 此处以JCore 2.9.0 版本为例。
implementation "io.objectbox:objectbox-android:$objectboxVersion"
annotationProcessor "io.objectbox:objectbox-processor:$objectboxVersion"
implementation 'me.jessyan:autosize:1.2.1'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
compileOnly 'com.google.android.wearable:wearable:2.7.0'
}