mirror of
https://github.com/niushuai233/DevControl.git
synced 2024-10-27 22:43:20 +08:00
feat: 引入greendao
This commit is contained in:
parent
b58b5aa668
commit
02d532fc31
@ -1,5 +1,6 @@
|
|||||||
plugins {
|
plugins {
|
||||||
id 'com.android.application'
|
id 'com.android.application'
|
||||||
|
id 'org.greenrobot.greendao'
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
@ -46,5 +47,17 @@ dependencies {
|
|||||||
implementation 'androidx.gridlayout:gridlayout:1.0.0'
|
implementation 'androidx.gridlayout:gridlayout:1.0.0'
|
||||||
|
|
||||||
// hutool
|
// hutool
|
||||||
implementation 'cn.hutool:hutool-all:5.8.8'
|
implementation 'cn.hutool:hutool-core:5.8.8'
|
||||||
|
|
||||||
|
// greendao
|
||||||
|
implementation 'org.greenrobot:greendao:3.3.0'
|
||||||
|
}
|
||||||
|
|
||||||
|
greendao {
|
||||||
|
// 数据库版本号
|
||||||
|
schemaVersion 1
|
||||||
|
// 生成数据库文件的目录
|
||||||
|
targetGenDir 'src/main/java'
|
||||||
|
// 生成的数据库相关文件的包名
|
||||||
|
daoPackage 'cc.niushuai.project.devcontrol.db.greendao.gen'
|
||||||
}
|
}
|
12
build.gradle
12
build.gradle
@ -1,4 +1,16 @@
|
|||||||
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
||||||
|
|
||||||
|
buildscript {
|
||||||
|
repositories {
|
||||||
|
jcenter()
|
||||||
|
google()
|
||||||
|
mavenCentral()
|
||||||
|
}
|
||||||
|
dependencies {
|
||||||
|
classpath 'org.greenrobot:greendao-gradle-plugin:3.3.0'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id 'com.android.application' version '7.1.3' apply false
|
id 'com.android.application' version '7.1.3' apply false
|
||||||
id 'com.android.library' version '7.1.3' apply false
|
id 'com.android.library' version '7.1.3' apply false
|
||||||
|
Loading…
x
Reference in New Issue
Block a user