【问题标题】:Grails 2.1.2 - UNRESOLVED DEPENDENCIES ErrorGrails 2.1.2 - 未解决的依赖项错误
【发布时间】:2012-12-27 06:15:18
【问题描述】:

我在 Windows 7 64 位系统上使用 Grails 2.1.2,在编译时出现以下错误,请帮我解决这个问题。

 ::::::::::::::::::::::::::::::::::::::::::::::

 ::          UNRESOLVED DEPENDENCIES         ::

 ::::::::::::::::::::::::::::::::::::::::::::::

 :: org.grails.plugins#mail;1.0-SNAPSHOT: not found

 :: org.grails.plugins#tomcat;1.3.2: not found

 :: org.grails.plugins#hibernate;1.3.2: not found

 :: org.grails.plugins#csl-rest-lib;1.0: not found

 ::::::::::::::::::::::::::::::::::::::::::::::

【问题讨论】:

    标签: grails


    【解决方案1】:

    在 BuildConfig.groovy 中,尝试声明依赖:

    dependencies {
        compile 'org.grails.plugins:mail:1-0-SNAPSHOT'
        compile 'org.grails.plugins:tomcat:1.3.2'
        ...
    }
    

    【讨论】:

      【解决方案2】:

      如果您的应用程序是从 grails 1.3 () 更新或从 grails 2 创建的。,您需要检查 grails plugins 上的插件版本 例如,邮件插件的当前版本是 1.0.1 mail plugin 您还需要在 conf/BuildConfig.groovy 中检查此依赖项。它必须有这样的部分:

      plugins {
              build ":tomcat:$grailsVersion"
      
              runtime ":hibernate:${grailsVersion}"
              runtime ":resources:1.1.6"
      ...
      

      在plugins 部分描述您的插件。 你需要检查最新的插件库并像这样描述它:

      dependencies {
              // specify dependencies here under either 'build', 'compile', 'runtime', 'test' or 'provided' scopes eg.
      
              compile('org.apache.poi:poi:3.7',
                      'org.apache.poi:poi-contrib:3.6',
                      'org.apache.poi:poi-ooxml:3.7',
                      'antlr:antlr:2.7.6',
                      'org.apache.ant:ant-apache-log4j:1.7.1'
      ..
      

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2015-04-25
        • 2016-03-13
        • 2013-11-29
        • 2013-04-29
        • 2015-06-24
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多