I’m trying to publish my plugin with gradle’s publishing plugin (com.gradle.plugin-publish
), but I’m getting a rather inscrutable error when invoking the publishPlugins
target:
Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
at org.apache.tools.ant.util.LayoutPreservingProperties.removeCommentsEndingAt(LayoutPreservingProperties.java:599)
at org.apache.tools.ant.util.LayoutPreservingProperties.remove(LayoutPreservingProperties.java:198)
at org.apache.tools.ant.util.LayoutPreservingProperties.readLines(LayoutPreservingProperties.java:359)
at org.apache.tools.ant.util.LayoutPreservingProperties.load(LayoutPreservingProperties.java:142)
at com.gradle.publish.LoginTask.loadProperties(LoginTask.java:57)
at com.gradle.publish.PublishTask.buildOAuthClient(PublishTask.java:345)
at com.gradle.publish.PublishTask.doSignedPost(PublishTask.java:291)
at com.gradle.publish.PublishTask.publishToPortal(PublishTask.java:174)
at com.gradle.publish.PublishTask.publish(PublishTask.java:54)
at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:75)
at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.doExecute(AnnotationProcessingTaskFactory.java:226)
at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:219)
at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:208)
at org.gradle.api.internal.AbstractTask$TaskActionWrapper.execute(AbstractTask.java:585)
at org.gradle.api.internal.AbstractTask$TaskActionWrapper.execute(AbstractTask.java:568)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:80)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:61)
... 60 more
The build.gradle is here.