Uploaded image for project: 'Maven WAR Plugin'
  1. Maven WAR Plugin
  2. MWAR-15

Support separate generation of WAR's manifest.mf

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.0
    • None
    • None

    Description

      Attached is a "war:manifest" goal for programmatically generating the WAR's manifest.mf. This is not useful for the WAR generation (since the war plugin already supports generating the manifest at the time the war is created) but it is useful for use with IDEs that require the MANIFEST.MF in the source tree when working with a war project (in my case, IBM's Rational Software Architect).

      We configure this for use as follows:

      <plugin>
      <groupId>org.apache.maven.plugins</groupId>
      <artifactId>maven-war-plugin</artifactId>
      <configuration>
      <warSourceDirectory>WebContent</warSourceDirectory>
      <warSourceExcludes>WEB-INF/lib/*.jar</warSourceExcludes>
      <archive>
      <manifest>
      <addClasspath>true</addClasspath>
      <classpathPrefix>lib/</classpathPrefix>
      </manifest>
      </archive>
      </configuration>
      </plugin>

      It generates it to ${warSourceDirectory}/META-INF/MANIFEST.MF which is where RSA expects it to reside.

      Attachments

        1. WarManifestMojo.java
          3 kB
          Mike Perham

        Activity

          People

            mperham Mike Perham
            mperham Mike Perham
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: