Maven 1.x War Plugin
  1. Maven 1.x War Plugin
  2. MPWAR-1

war plugin doesn't copy resources in no sources present

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
      None
    • Environment:
      maven-war-plugin-1.4, although it is in 1.5-SNAPSHOT too
    • Number of attachments :
      0

      Description

      due to the use of sourcesPresent to avoid copying the classes directory, and running test:test + java:compile, any resources present in a webapp with no source do not get copied

        Activity

        Hide
        dion gillard added a comment -

        Can you give me some more detail?

        From the plugin:
        <j:if test="$

        {sourcesPresent == 'true'}

        ">
        <ant:copy todir="$

        {webapp.build.classes}

        ">
        <ant:fileset dir="$

        {maven.build.dest}

        "
        includes="$

        {maven.war.classes.includes}

        "
        excludes="$

        {maven.war.classes.excludes}

        ">
        </ant:fileset>
        </ant:copy>
        </j:if>

        This is not about copying <resources>, but classes.????

        Show
        dion gillard added a comment - Can you give me some more detail? From the plugin: <j:if test="$ {sourcesPresent == 'true'} "> <ant:copy todir="$ {webapp.build.classes} "> <ant:fileset dir="$ {maven.build.dest} " includes="$ {maven.war.classes.includes} " excludes="$ {maven.war.classes.excludes} "> </ant:fileset> </ant:copy> </j:if> This is not about copying <resources>, but classes.????
        Hide
        Brett Porter added a comment -

        the way resources are copied is via java:jar-resources, which puts them in maven.build.dest, which is then copied by the war plugin into WEB-INF/classes.

        If sourcesPresent is false, they never get there.

        Show
        Brett Porter added a comment - the way resources are copied is via java:jar-resources, which puts them in maven.build.dest, which is then copied by the war plugin into WEB-INF/classes. If sourcesPresent is false, they never get there.

          People

          • Assignee:
            Brett Porter
            Reporter:
            Brett Porter
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: