[
http://jira.codehaus.org/browse/MNG-4368?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=201551#action_201551
]
Tamás Cservenák commented on MNG-4368:
--------------------------------------
This is _completely wrong_, and makes Maven3 very cumbersome (if not completely
broken) to work on branches, especially with regarding POMs. What happens:
Check out a trunk of your project (let's suppose all files are modified today
T0):
* svn checkout
* mvn clean install
Then, tomorrow T1 do a branch of your project, and _modify_ for example the POM
of your project in branch.
* svn branch it
* mvn clean install
Then, next day T2, return to trunk and continue work (but for example's sake,
do _not_ modify the POM you changed in branch).
* svn switch back to trunk
* mvn clean instal
Obviously T0 < T1 < T2
But, the change done in T1 will be _*not replaceable*_ by the 2nd trunk build
(mvn clean install in T2 will *NOT* replace the pom in local repo), and
potentionally will result in very spurious errors (ie. in branch you remove/add
deps, change parent, etc).
Please, undo this! Thanks.
Interestingly, this will fit nicely with Git (git will "touch" the file when
switching back from branch to "master")
http://git.or.cz/gitwiki/GitSvnComparsion
http://git.or.cz/gitwiki/GitFaq#Whyisn.27tGitpreservingmodificationtimeonfiles.3F
But in general, on "install" goal Maven should install the files I told it to
install.
> DefaultArtifactInstaller should only overwrite files if timestamp has changed
> -----------------------------------------------------------------------------
>
> Key: MNG-4368
> URL: http://jira.codehaus.org/browse/MNG-4368
> Project: Maven 2
> Issue Type: Improvement
> Environment: Linux, JDK 1.5
> Reporter: Johannes Martin
> Fix For: 2.2.2, 3.0-alpha-3
>
>
> install:install (from maven-install-plugin) by default uses
> DefaultArtifactInstaller to install artifacts. DefaultArtifactInstaller in
> turn uses FileUtils.copyFile(), thereby overwriting destination files even if
> they are unchanged. It would be helpful if DefaultArtifactInstaller used
> FileUtils.copyFileIfModified() instead, at least as an option, to speed up
> the build process.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira