You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "rich zaleski (JIRA)" <ji...@codehaus.org> on 2010/02/02 18:27:55 UTC

[jira] Commented: (MWAR-121) Maven-war-plugin not installing war. Installs ".jar" and renames it to ".war"

    [ http://jira.codehaus.org/browse/MWAR-121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=208951#action_208951 ] 

rich zaleski commented on MWAR-121:
-----------------------------------

It would be great if this would be fixed.  It seems the maven-source-plugin works properly, but the maven-war-plugin does not.  I would like to generate primary and secondary artifacts using a single pom file. It seems overly complex to have to make modules out of everything. 

     <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <executions>
          <execution>
            <id>default-jar</id>
            <phase>package</phase>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
			
      <plugin>
        <artifactId>maven-war-plugin</artifactId>
        <configuration>
          <warName>cds_commons</warName>
        </configuration>
        <executions>
          <execution>
            <id>attach-war</id>
            <phase>package</phase>
            <goals>
              <goal>war</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <executions>
          <execution>
           <id>attach-sources</id>
           <phase>package</phase>
           <goals>
             <goal>jar</goal>
           </goals>
        </execution>
       </executions>
    </plugin>
  < /plugins>
 </build>

> Maven-war-plugin not installing war. Installs ".jar" and renames it to ".war"
> -----------------------------------------------------------------------------
>
>                 Key: MWAR-121
>                 URL: http://jira.codehaus.org/browse/MWAR-121
>             Project: Maven 2.x WAR Plugin
>          Issue Type: Bug
>         Environment: Windows XP
> Maven  2.0.7
> JDK 1.5.0_10
>            Reporter: Dave Rathnow
>            Assignee: Stephane Nicoll
>         Attachments: war.zip
>
>
> I'm trying to use the maven-war-plugin to install a war into my local repository.  "mvn clean install" runs fine and completes succesfully.  If I look under the target" directory in the project folder, there is, amoung other things, a .jar and .war file.  Both have been built properly.  However, if I look in my local repository, there is a .war file but when I open it, it is actually the .jar file renamed  to .war.
> The attached zip file contains the pom for the project, the parent pom and the output from the command "mvn clean install -X > output.log"

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira