无法在Grails 2.3.11中导入本地插件

时间:2014-10-15 08:26:02

标签: grails grails-2.0 grails-plugin

我无法在我的应用程序中导入本地插件,这些约定:

grails.plugin.location.MyPlugin= '../MyPlugin'

grails.plugin.location.'MyPlugin' = '../MyPlugin'

grails.plugin.location.'MyPlugin' = 'c:/prj/MyPlugin'

grails.plugin.location.'MyPlugin' = 'c:\\prj\\MyPlugin'

在插件conf。中有或没有这个。

    //compile ":myplugin:0.1-SNAPSHOT"

结果是:

|运行Grails应用程序

Error |
WARNING: Inline plugins for [MyPlugin] cannot be read due to error: ivy pattern must be absolute: 
    C:\Users\Luigi\.m2\repository
  /[organisation]/[module]/[revision]/[module]-[revision](-[classifier]).pom (Use --stacktrace to see the full trace)

1 个答案:

答案 0 :(得分:0)

尝试这样(我的主页路径' / home',插件是' urlrewrite')

grails.project.dependency.resolver = "maven" // or ivy

//use a copy of urlrewrite fixed in enviroment PRODUCCTION because, the repo don't have a functional version for grails 2.5.0
if (Environment.current == Environment.PRODUCTION) {
    grails.plugin.location.urlrewrite = '/home/sam/Repositorios/BTask/Programacion/BTask/src/plugins/urlrewrite-0.1'
}

grails.project.dependency.resolution = {
...