2013-10-10 114 views
1

我必須使用現有的grails項目,使用grails版本2.0.4 當我嘗試運行項目時,我的grails插件出現錯誤「image-tools」安裝grails插件圖像工具1.0.5

Error Failed to resolve dependencies (Set log level to 'warn' in BuildConfig.groovy for more information): - org.grails.plugins:image-tools:1.0.5

在BuildConfig.groovy

我有:

plugins { 
    ... 
    compile ':image-tools:1.0.5' 
    ... 
} 

application.properties:

plugins.image-tools=1.0.5 

所以我試圖重新安裝插件,但我總是得到這個錯誤:

| Environment set to development..... 
:: problems summary :: 
:::: WARNINGS 
    module not found: commons-collections#commons-collections;3.1 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-collections/commons-collections/ivy-3.1.xml 
    -- artifact commons-collections#commons-collections;3.1!commons-collections.jar: 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-collections/commons-collections/jars/commons-collections-3.1.jar 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-collections/commons-collections/bundles/commons-collections-3.1.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-collections-3.1.xml 
    -- artifact commons-collections#commons-collections;3.1!commons-collections.jar: 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-collections-3.1.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-collections-3.1.xml 
    -- artifact commons-collections#commons-collections;3.1!commons-collections.jar: 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-collections-3.1.jar 
==== grailsHome: tried 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-collections-3.1.xml 
    -- artifact commons-collections#commons-collections;3.1!commons-collections.jar: 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-collections-3.1.jar 
==== grailsHome: tried 
    -- artifact commons-collections#commons-collections;3.1!commons-collections.jar: 
    /home/proxymit/.gvm/grails/2.0.4/plugins/commons-collections-3.1.jar 
==== image-tools plugin install resolver: tried 
    -- artifact commons-collections#commons-collections;3.1!commons-collections.jar: 
    /home/proxymit/grails-imagetools-master/commons-collections-3.1.jar 
    /home/proxymit/grails-imagetools-master/grails-commons-collections-3.1.jar 
    module not found: commons-codec#commons-codec;1.3 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-codec/commons-codec/ivy-1.3.xml 
    -- artifact commons-codec#commons-codec;1.3!commons-codec.jar: 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-codec/commons-codec/jars/commons-codec-1.3.jar 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-codec/commons-codec/bundles/commons-codec-1.3.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-codec-1.3.xml 
    -- artifact commons-codec#commons-codec;1.3!commons-codec.jar: 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-codec-1.3.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-codec-1.3.xml 
    -- artifact commons-codec#commons-codec;1.3!commons-codec.jar: 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-codec-1.3.jar 
==== grailsHome: tried 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-codec-1.3.xml 
    -- artifact commons-codec#commons-codec;1.3!commons-codec.jar: 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-codec-1.3.jar 
==== grailsHome: tried 
    -- artifact commons-codec#commons-codec;1.3!commons-codec.jar: 
    /home/proxymit/.gvm/grails/2.0.4/plugins/commons-codec-1.3.jar 
==== image-tools plugin install resolver: tried 
    -- artifact commons-codec#commons-codec;1.3!commons-codec.jar: 
    /home/proxymit/grails-imagetools-master/commons-codec-1.3.jar 
    /home/proxymit/grails-imagetools-master/grails-commons-codec-1.3.jar 
    module not found: commons-beanutils#commons-beanutils;1.8.0 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-beanutils/commons-beanutils/ivy-1.8.0.xml 
    -- artifact commons-beanutils#commons-beanutils;1.8.0!commons-beanutils.jar: 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-beanutils/commons-beanutils/jars/commons-beanutils-1.8.0.jar 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-beanutils/commons-beanutils/bundles/commons-beanutils-1.8.0.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-beanutils-1.8.0.xml 
    -- artifact commons-beanutils#commons-beanutils;1.8.0!commons-beanutils.jar: 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-beanutils-1.8.0.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-beanutils-1.8.0.xml 
    -- artifact commons-beanutils#commons-beanutils;1.8.0!commons-beanutils.jar: 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-beanutils-1.8.0.jar 
==== grailsHome: tried 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-beanutils-1.8.0.xml 
    -- artifact commons-beanutils#commons-beanutils;1.8.0!commons-beanutils.jar: 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-beanutils-1.8.0.jar 
==== grailsHome: tried 
    -- artifact commons-beanutils#commons-beanutils;1.8.0!commons-beanutils.jar: 
    /home/proxymit/.gvm/grails/2.0.4/plugins/commons-beanutils-1.8.0.jar 
==== image-tools plugin install resolver: tried 
    -- artifact commons-beanutils#commons-beanutils;1.8.0!commons-beanutils.jar: 
    /home/proxymit/grails-imagetools-master/commons-beanutils-1.8.0.jar 
    /home/proxymit/grails-imagetools-master/grails-commons-beanutils-1.8.0.jar 
    module not found: commons-lang#commons-lang;2.4 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-lang/commons-lang/ivy-2.4.xml 
    -- artifact commons-lang#commons-lang;2.4!commons-lang.jar: 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-lang/commons-lang/jars/commons-lang-2.4.jar 
    /home/proxymit/.gvm/grails/2.0.4/lib/commons-lang/commons-lang/bundles/commons-lang-2.4.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-lang-2.4.xml 
    -- artifact commons-lang#commons-lang;2.4!commons-lang.jar: 
    /home/proxymit/.gvm/grails/2.0.4/src/libs/commons-lang-2.4.jar 
==== grailsHome: tried 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-lang-2.4.xml 
    -- artifact commons-lang#commons-lang;2.4!commons-lang.jar: 
    /home/proxymit/.gvm/grails/2.0.4/dist/commons-lang-2.4.jar 
==== grailsHome: tried 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-lang-2.4.xml 
    -- artifact commons-lang#commons-lang;2.4!commons-lang.jar: 
    /home/proxymit/.grails/2.0.4/cached-installed-plugins/commons-lang-2.4.jar 
==== grailsHome: tried 
    -- artifact commons-lang#commons-lang;2.4!commons-lang.jar: 
    /home/proxymit/.gvm/grails/2.0.4/plugins/commons-lang-2.4.jar 
==== image-tools plugin install resolver: tried 
    -- artifact commons-lang#commons-lang;2.4!commons-lang.jar: 
    /home/proxymit/grails-imagetools-master/commons-lang-2.4.jar 
    /home/proxymit/grails-imagetools-master/grails-commons-lang-2.4.jar 
    :::::::::::::::::::::::::::::::::::::::::::::: 
    ::   UNRESOLVED DEPENDENCIES   :: 
    :::::::::::::::::::::::::::::::::::::::::::::: 
    :: commons-collections#commons-collections;3.1: not found 
    :: commons-codec#commons-codec;1.3: not found 
    :: commons-beanutils#commons-beanutils;1.8.0: not found 
    :: commons-lang#commons-lang;2.4: not found 
    :::::::::::::::::::::::::::::::::::::::::::::: 

| Error Could not resolve all dependencies for plugin image-tools 
+2

定義在'不需要application.properties'插件的第一件事。由於這是Grails 2.x,buildConfig就足夠了。也可以發佈完整的buidconfig.groovy。 – Alidad

+0

這個插件版本存在嗎? http://grails.org/plugin/image-tools –

+0

@SérgioMichels,看起來像Github上的版本,但不是Grails的repo:https://github.com/ricardojmendez/grails-imagetools/commits/master – grantmcconnaughey

回答

2

終於它的工作原理,這裏就是我所做的:

我下載的插件壓縮來自:https://github.com/ricardojmendez/grails-imagetools 然後我extact它

cd (plugin directory) 
grails upgrade 
grails create-plugin ImageTools 
grails package-plugin 
cd (to the project using the plugin) 
grails install-plugin (path to created plugin) 

然後我評論其他安裝的插件中​​buildConfig.groovy和application.properties中

然後我instaleld個從外掛程序的genereted .ZIP

最後我註釋掉其他插件和運行應用程序

+1

只是一個注意:在Grails 2.x中不推薦使用install-plugin,你可以這樣做:'grails package-plugin'安裝在本地maven倉庫中,然後使用'BuildConfig.groovy'聲明插件。你也可以在github中提出一個問題,看看這個版本是否應該在grails.org上可用。 –