Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-6898

Support Escape Characters in Target Field

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Trivial Trivial
    • grails-plugin
    • None
    • Windows Server 2008

      There is an outstanding issue with Grails on certain environments (see: http://jira.codehaus.org/browse/GRAILS-4295) where parameters are not parsed correctly. The work around is to surround the parameter in double quotes so for example:

      grails maven-deploy "--repository=snapshot"

      The problem lies in that you can't escape the inner quotes in the Target field when building a Hudson project so:

      "grails maven-deploy \"--repository=snapshot\""

      Throws the following error when the project is next built:
      org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed, Script1.groovy: 1: expecting EOF, found 'repository' @ line 1, column 12.
      1 error

      at org.codehaus.groovy.control.ErrorCollector.failIfErrors(ErrorCollector.java:296)
      at org.codehaus.groovy.control.ErrorCollector.addFatalError(ErrorCollector.java:143)
      at org.codehaus.groovy.control.ErrorCollector.addError(ErrorCollector.java:113)
      at org.codehaus.groovy.control.ErrorCollector.addError(ErrorCollector.java:125)
      at org.codehaus.groovy.control.SourceUnit.addError(SourceUnit.java:353)
      at org.codehaus.groovy.antlr.AntlrParserPlugin.transformCSTIntoAST(AntlrParserPlugin.java:92)
      at org.codehaus.groovy.antlr.AntlrParserPlugin.parseCST(AntlrParserPlugin.java:59)
      at org.codehaus.groovy.control.SourceUnit.parse(SourceUnit.java:249)
      at org.codehaus.groovy.control.CompilationUnit$1.call(CompilationUnit.java:160)
      at org.codehaus.groovy.control.CompilationUnit.applyToSourceUnits(CompilationUnit.java:801)
      at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:466)
      at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:281)
      at groovy.lang.GroovyShell.parseClass(GroovyShell.java:590)
      at groovy.lang.GroovyShell.parse(GroovyShell.java:602)
      at groovy.lang.GroovyShell.parse(GroovyShell.java:582)
      at groovy.lang.GroovyShell.evaluate(GroovyShell.java:560)
      at groovy.lang.GroovyShell.evaluate(GroovyShell.java:536)
      at com.g2one.hudson.grails.GrailsBuilder.evalTarget(GrailsBuilder.java:212)
      at com.g2one.hudson.grails.GrailsBuilder.perform(GrailsBuilder.java:168)
      at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
      at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:600)
      at hudson.model.Build$RunnerImpl.build(Build.java:174)
      at hudson.model.Build$RunnerImpl.doRun(Build.java:138)
      at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:416)
      at hudson.model.Run.run(Run.java:1244)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
      at hudson.model.ResourceController.execute(ResourceController.java:88)
      at hudson.model.Executor.run(Executor.java:122)

            jeffg2one jeffg2one
            scheeser scheeser
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: