Add submodule POMs as job artifacts

Release 3.7.0 added the "inject branch slug into SNAPSHOT version (6fc68178)" feature that modifies one or more of the project's POMs, however currently only the main (parent) POM is added as a job artifact.

This leads to issues in multi-module Maven projects where submodules are not able to resolve their parent POM in later jobs.

Example error from mvn-sonar job in a multi-module Maven project:

[ERROR] Some problems were encountered while processing the POMs: [FATAL] Non-resolvable parent POM for com.example:submodule:1.0.0-SNAPSHOT: The following artifacts could not be resolved: com.example:parent:pom:1.0.0-SNAPSHOT (absent): Could not find artifact com.example:parent:pom:1.0.0-SNAPSHOT and 'parent.relativePath' points at wrong local POM


Suggestion: Add all POMs as artifacts:

  artifacts:
    paths:
      # version may have been altered
      - "${MAVEN_PROJECT_DIR}/**/pom.xml"
      - "${MAVEN_PROJECT_DIR}/**/target"
Edited by Bragolgirith