grails-plugins/grails-svn — Issue #1: Conflicts with Publish Plugin
Author: joergrech
Created: 2012-02-11 12:07:02+00:00
State: open

Hi,
I think the SVN plugin has some problems with the Publish plugin when I want to publish a plugin. After calling "publish-plugin --stacktrace" I get the following output:

```
| Loading Grails 2.0.0
| Configuring classpath.
| Environment set to development.....
| Packaging Grails application.....
| Plugin packaged grails-kickstart-with-bootstrap-0.5.3.zip
| Generating POM file.....
| POM generated: C:\Users\rech\Git\KickstartWithBootstrap\kickstartWithBootstrap\target/pom.xml
> Enter extra commit message text for this release (optional):
> Project is not under source control. Do you want to import it now? (Y,n)
> Would you like to add this plugin's source to the Grails plugin source repository? (Y,n) n
> Please enter the URL of the remote SCM repository:
| Error Error executing script PublishPlugin: java.lang.ArrayIndexOutOfBoundsException: Negative array index [-1] too large for array size 0 (NOTE: Stack trace has been filtered. Use --verbose to see entire trace.)
java.lang.ArrayIndexOutOfBoundsException: Negative array index [-1] too large for array size 0
at grails.plugin.svn.SvnClient.stripProjectPath(SvnClient.groovy:457)
at grails.plugin.svn.SvnClient.(SvnClient.groovy:61)
at grails.plugin.svn.SvnScmProvider.importIntoRepo(SvnScmProvider.groovy:74)
at PublishPlugin.scmImportProject(PublishPlugin:499)
at PublishPlugin.this$4$scmImportProject(PublishPlugin)
at PublishPlugin$this$4$scmImportProject.callCurrent(Unknown Source)
at PublishPlugin.processScm(PublishPlugin:446)
at PublishPlugin.this$4$processScm(PublishPlugin)
at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
at PublishPlugin$_run_closure1.doCall(PublishPlugin:105)
at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
at gant.Gant$_dispatch_closure5.doCall(Gant.groovy:381)
at gant.Gant$_dispatch_closure7.doCall(Gant.groovy:415)
at gant.Gant$_dispatch_closure7.doCall(Gant.groovy)
at gant.Gant.withBuildListeners(Gant.groovy:427)
at gant.Gant.this$2$withBuildListeners(Gant.groovy)
at gant.Gant$this$2$withBuildListeners.callCurrent(Unknown Source)
at gant.Gant.dispatch(Gant.groovy:415)
at gant.Gant.this$2$dispatch(Gant.groovy)
at gant.Gant.invokeMethod(Gant.groovy)
at gant.Gant.executeTargets(Gant.groovy:591)
at gant.Gant.executeTargets(Gant.groovy:590)
| Error Error executing script PublishPlugin: java.lang.ArrayIndexOutOfBoundsException: Negative array index [-1] too large for array size 0
```
Notes:
* I removed the config "grails.release.scm.enabled = false" from setting.groovy (with it it will also not work)
* I tested SVN 1.0.2 and 1.0.3-SNAPSHOT with RELEASE 1.0.1

This problem might be connected to the SVN credential /initial-use problem of the release plugin http://jira.grails.org/browse/GPRELEASE-19?focusedCommentId=69371