Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-6223

mvn -f outputs invalid error when specifying POM directory

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.5.0-alpha-1, 3.5.0
    • Fix Version/s: 3.5.2
    • Component/s: Command Line
    • Labels:
      None
    • Environment:

      Description

      Basic multi-module project: common, client, and server modules.

      $ mvn -f client package
      POM file client specified with the -f/--file command line argument does not exist
      [INFO] Scanning for projects...
      [INFO]
      [INFO] ------------------------------------------------------------------------
      [INFO] Building alternate-pom-client 1.0
      [INFO] ------------------------------------------------------------------------
      [INFO]
      [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ alternate-pom-client ---
      [INFO] Using 'UTF-8' encoding to copy filtered resources.
      [INFO] skip non existing resourceDirectory /Users/cgould/dev/personal/alternate-pom/client/src/main/resources
      [INFO]
      [INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ alternate-pom-client ---
      [INFO] Nothing to compile - all classes are up to date
      [INFO]
      [INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ alternate-pom-client ---
      [INFO] Using 'UTF-8' encoding to copy filtered resources.
      [INFO] skip non existing resourceDirectory /Users/cgould/dev/personal/alternate-pom/client/src/test/resources
      [INFO]
      [INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ alternate-pom-client ---
      [INFO] No sources to compile
      [INFO]
      [INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ alternate-pom-client ---
      [INFO] No tests to run.
      [INFO]
      [INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ alternate-pom-client ---
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD SUCCESS
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 0.764 s
      [INFO] Finished at: 2017-04-29T14:03:22-04:00
      [INFO] Final Memory: 11M/309M
      [INFO] ------------------------------------------------------------------------
      

      There is an error message, but the client module proceeds to build nonetheless.

      I don't see the error message when I run:

      $ mvn -f client/pom.xml package
      

      I've verified it doesn't happen on 3.3.9, but it does happen on 3.5.0 and 3.5.0-alpha-1.

      Sample project attached.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                hboutemy Hervé Boutemy
                Reporter:
                cgould Charles Gould
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: