我已经回答了类似问题的一些答案,但我仍然无法解决这个问题。我在BuildConfig中包含了以下内容 -
dependencies {
...
compile ':spring-security-core:2.0-RC2'
}
repositories {
...
mavenRepo "http://repo.spring.io/milestone"
}
但是,当我运行应用程序时,它会给我以下错误 -
| Downloading: spring-security-core-2.0-RC2.pom
:: problems summary ::
:::: ERRORS
grailsCentral: bad organisation found in http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_2_0-RC2/spring-security-core-2.0-RC2.pom: expected='' found='org.grails.plugins'
http://grails.org/plugins: bad organisation found in http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_2_0-RC2/spring-security-core-2.0-RC2.pom: expected='' found='org.grails.plugins'
| Downloading: spring-security-core-2.0-RC2.pom
:: problems summary ::
:::: ERRORS
grailsCentral: bad organisation found in http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_2_0-RC2/spring-security-core-2.0-RC2.pom: expected='' found='org.grails.plugins'
http://grails.org/plugins: bad organisation found in http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_2_0-RC2/spring-security-core-2.0-RC2.pom: expected='' found='org.grails.plugins'
| Downloading: spring-security-core-2.0-RC2.pom
:: problems summary ::
:::: ERRORS
grailsCentral: bad organisation found in http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_2_0-RC2/spring-security-core-2.0-RC2.pom: expected='' found='org.grails.plugins'
http://grails.org/plugins: bad organisation found in http://grails.org/plugins/grails-spring-security-core/tags/RELEASE_2_0-RC2/spring-security-core-2.0-RC2.pom: expected='' found='org.grails.plugins'
| Error Failed to resolve dependencies (Set log level to 'warn' in BuildConfig.groovy for more information):
- :spring-security-core:2.0-RC2
我无法弄清楚我做错了什么。我尝试使用install-plugin手动添加它,但即便抛出错误。
如果它有用,我使用eclipse IDE进行spring / grails及其Grails 2.2.4项目。
答案 0 :(得分:4)
Jar依赖项进入依赖项块。将插件依赖项放在插件块中。