【发布时间】:2020-10-23 09:08:22
【问题描述】:
我正在尝试构建 LineageOS 的投石机发射器。更新 protobuf 插件后,我设法摆脱了一些错误。但是经过几次尝试我无法处理这个错误:
无法获取根项目的未知属性“插件” 'android_packages_apps_Trebuchet-lineage-16.0' 类型 org.gradle.api.Project.
这是我第一次从 Github 编辑代码。请帮忙。
buildscript {
repositories {
mavenCentral()
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.6.2'
classpath 'com.google.protobuf:protobuf-gradle-plugin:0.8.13'
}
}
apply plugin 'com.android.application'
apply plugin 'com.google.protobuf' version '0.8.13'
final String SUPPORT_LIBS_VERSION = '28.0.0'
android {
defaultConfig {
compileSdkVersion 28
minSdkVersion 21
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
}
buildTypes {
debug {
minifyEnabled false
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
这之后还有很多代码,看起来并不重要所以没有添加。如果需要,请告诉我
【问题讨论】:
标签: android android-studio gradle groovy build.gradle