【发布时间】:2021-02-07 16:22:54
【问题描述】:
我正在使用 Grails 项目,我将我的 gradle-wrapper 从“gradle-2.9-all”更新为“gradle-3.0-bin”,我收到了这个错误:
应用插件请求时发生异常 [id: 'io.spring.dependency-management',版本:`'0.5.2.RELEASE'] 失败 应用插件 [id 'io.spring.dependency-management'] 不能 创建“DependencyManagementReportTask”类型的任务。
我的 build.gradle:
buildscript {
ext {
grailsVersion = project.grailsVersion
}
repositories {
mavenLocal()
maven { url "https://repo.grails.org/grails/core" }
}
dependencies {
classpath "org.grails:grails-gradle-plugin:$grailsVersion"
classpath 'com.bertramlabs.plugins:asset-pipeline-gradle:2.5.0'
classpath "org.grails.plugins:hibernate4:5.0.4"
}
}
plugins {
id "io.spring.dependency-management" version "0.5.2.RELEASE"
}
version "1.0.0"
group "project"
apply plugin: "spring-boot"
apply plugin: "war"
apply plugin: "asset-pipeline"
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: "org.grails.grails-web"
apply plugin: "org.grails.grails-gsp"
ext {
grailsVersion = project.grailsVersion
gradleWrapperVersion = project.gradleWrapperVersion
}
【问题讨论】: