maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stijnkoopal <stijn.koo...@gmail.com>
Subject Maven plugin plugin with Jenkins job containing / (slash)
Date Wed, 20 Jul 2016 08:43:59 GMT
Hi,

Currently we are using jgitflow maven plugin that generates git branches for
us. These git branches are named /feature/some-name-here/. Furthermore, we
are using jenkins to build our repos. Specifically, we are using the sync
plugin which generates jobs based on git branches. 

The jenkins jobs that are generated by the sync plugin are named after the
branch name. So for a feature branch, the name /feature/some-name-here/ is
created. The problem now is that when a feature branch contains a
maven-plugin (backed by maven-plugin-plugin in the build section of the
pom), an exception is thrown during the jenkins build:
java.lang.RuntimeException: Cannot read file : TestMojo.java. Locally all is
working perfectly.

If we replace slash in the name of the jenkins job to dash (-), then all is
working.

 POM:
<build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-plugin-plugin</artifactId>
                <version>3.3</version>
                <configuration>
                    <goalPrefix>kjar</goalPrefix>
                </configuration>
                <executions>
                    <execution>
                        <id>default-descriptor</id>
                        <goals>
                            <goal>descriptor</goal>
                        </goals>
                        <phase>process-classes</phase>
                    </execution>
                    <execution>
                        <id>help-descriptor</id>
                        <goals>
                            <goal>helpmojo</goal>
                        </goals>
                        <phase>process-classes</phase>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

TestMojo:

import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.MojoFailureException;

@Mojo(name = "test")
public class TestMojo extends AbstractMojo {
    @Override
    public void execute() throws MojoExecutionException,
MojoFailureException {
        
    }
}

Should I file a jira ticket for this issue?



--
View this message in context: http://maven.40175.n5.nabble.com/Maven-plugin-plugin-with-Jenkins-job-containing-slash-tp5875855.html
Sent from the Maven - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Mime
View raw message