[
https://issues.apache.org/jira/browse/MWRAPPER-42?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17462411#comment-17462411
]
Herve Boutemy commented on MWRAPPER-42:
---------------------------------------
nice finding, nice report
I suppose that we can compare date of mvnw[.com] with maven-wrapper.jar: if
script is strictly newer, maven-wrapper.jar has to be deleted, to be downloaded
again
coding that in *nix is easy (the hardest part is making sure it is portable)
I don't know about .cmd: any hint better what I found in SO than
https://stackoverflow.com/questions/1687014/how-do-i-compare-timestamps-of-files-in-a-batch-script
?
> maven-wrapper fails to self-update maven-wrapper.jar
> ----------------------------------------------------
>
> Key: MWRAPPER-42
> URL: https://issues.apache.org/jira/browse/MWRAPPER-42
> Project: Maven Wrapper
> Issue Type: Bug
> Components: Maven Wrapper Scripts
> Affects Versions: 3.1.0
> Reporter: Jeremy Norris
> Priority: Major
>
> In cases where users do not check-in the maven-wrapper.jar into their
> repositories, after executing `mvn wrapper:wrapper -Dtype=script` to update,
> the newly updated `mvnw` script will continue to use an older version of
> `.mvn/wrapper/maven-wrapper.jar` that was previously downloaded.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)