-
Notifications
You must be signed in to change notification settings - Fork 4
Modify plugin arguments in pom.xml #340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Updated Maven plugin arguments to include -am flag.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR modifies Maven build arguments to exclude the xapi-build parent POM from deployment and adds the -am (also-make) flag to build dependencies.
Key Changes
- Removes
xapi-buildfrom the project list (-pl) in deployment commands - Adds the
-amflag to ensure dependencies are built before deployment - Changes are applied consistently across both Maven Release Plugin configuration and GitHub Actions snapshot publishing workflow
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| pom.xml | Modified maven-release-plugin arguments to exclude xapi-build and add -am flag for dependency building |
| .github/workflows/maven-publish-snapshot.yml | Updated snapshot deployment command to match pom.xml changes by removing xapi-build and adding -am flag |
| <goals>deploy</goals> | ||
| <!-- Only release production modules, exclude all sample modules --> | ||
| <arguments>-pl xapi-build,xapi-model,xapi-client,xapi-model-spring-boot-starter</arguments> | ||
| <arguments>-pl xapi-model,xapi-client,xapi-model-spring-boot-starter -am</arguments> |
Copilot
AI
Nov 16, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing xapi-build from the -pl argument may cause issues for consumers. The child modules (xapi-model, xapi-client, xapi-model-spring-boot-starter) reference xapi-build as their parent in their POMs. When these artifacts are published to Maven Central, they will contain this parent reference, which means Maven needs to be able to resolve the xapi-build POM.
With this change, only the three explicitly listed modules will be deployed, not the parent POM. This could result in "Could not find artifact dev.learning.xapi:xapi-build:pom:version" errors for consumers.
The -am (also-make) flag ensures that dependencies are built before the specified modules, but it does not affect which modules are deployed - only modules in the -pl list are deployed.
Consider whether the parent POM should remain in the deployment list, or if there's another mechanism to ensure it's published to Maven Central.
|
|
||
| - name: Publish snapshot package | ||
| run: mvn -B deploy --file pom.xml -pl xapi-build,xapi-model,xapi-client,xapi-model-spring-boot-starter | ||
| run: mvn -B deploy --file pom.xml -pl xapi-model,xapi-client,xapi-model-spring-boot-starter -am |
Copilot
AI
Nov 16, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing xapi-build from the -pl argument may cause issues for consumers. The child modules (xapi-model, xapi-client, xapi-model-spring-boot-starter) reference xapi-build as their parent in their POMs. When these artifacts are published to the snapshot repository, they will contain this parent reference, which means Maven needs to be able to resolve the xapi-build POM.
With this change, only the three explicitly listed modules will be deployed, not the parent POM. This could result in "Could not find artifact dev.learning.xapi:xapi-build:pom:version" errors for consumers of snapshot versions.
The -am (also-make) flag ensures that dependencies are built before the specified modules, but it does not affect which modules are deployed - only modules in the -pl list are deployed.
Consider whether the parent POM should remain in the deployment list, or if there's another mechanism to ensure it's published to the snapshot repository.
| run: mvn -B deploy --file pom.xml -pl xapi-model,xapi-client,xapi-model-spring-boot-starter -am | |
| run: mvn -B deploy --file pom.xml -pl xapi-build,xapi-model,xapi-client,xapi-model-spring-boot-starter -am |



No description provided.