elharo opened a new pull request, #264:
URL: https://github.com/apache/maven-artifact-plugin/pull/264

   Follow-up to #262, which bumped `maven-shared-utils` from 3.4.2 to 3.5.0. 
That release deprecates `org.apache.maven.shared.utils.logging.MessageUtils`, 
so the build now warns at every call site.
   
   ## Why not switch to `MessageBuilderFactory`?
   
   3.5.0's deprecation notice points at 
`org.apache.maven.message.MessageBuilderFactory`, but that API only exists in 
Maven 3.10.0+, and the `org.apache.maven.api.services` variant only in Maven 4. 
This plugin's prerequisite is still Maven 3.6.3, so adopting either one means a 
prerequisite bump (or reflection) purely to keep a cosmetic feature. 
`MessageBuilder` is itself deprecated in the same release, so it isn't a way 
out either.
   
   So: drop the styling instead of raising prerequisites.
   
   ## What changed
   
   `describe-build-output` and `compare` now emit plain text. 
`maven-shared-utils` had no other use in the plugin — the pom even said `<!-- 
ONLY: MessageUtil -->` — so the dependency is dropped as well, taking its 
transitive Jansi chain with it.
   
   ## Verification
   
   - With `-Dstyle.color=never` the output is **byte-for-byte identical** to 
before. I diffed old vs. new for:
     - `describe-build-output`, including the header line, the 
`:classifier:extension` column, the `target/` path prefix, and the 
repository-filename column;
     - the `compare` summary line, in both its all-matching (`N files match`) 
and failing (`N files match, N differ`) forms;
     - the `compare` mismatch line (`... mismatch <file>: investigate with 
diffoscope ...`).
   - With `-Dstyle.color=always` the only difference is the plugin's own escape 
sequences disappearing, which is the point. Maven's own `[INFO]`/`[ERROR]` 
prefix coloring is unchanged.
   - Generated `.buildinfo` and `.buildcompare` files are unaffected (they were 
never styled).
   - `mvn clean verify -Prun-its`: BUILD SUCCESS, 0 Checkstyle violations, 
16/16 ITs pass, no `dependency:analyze` problems.
   
   The only remaining deprecation warnings are the two `@Component` ones in 
`ReproducibleCentralReport`, which are fixed by #261 and are not on `master` 
yet.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to