[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

svn rename adds mergeinfo property / renaming in working copy does not

From: Nicolai Scheer <nicolai.scheer_at_gmail.com>
Date: Mon, 6 Nov 2017 18:10:37 +0100

Hi all,

I just stumbled across a very strange behaviour.
We're using a pre-commit hook, that checks if a commit involves a merge
operation.
If the operation does involve a merge, we force the user to use the word
"merge" in the commit message.

I implented this using

svnlook diff --no-diff-deleted --no-diff-added -t XXXXXX /my/path/to/repo

and analysing if the string "Added: svn:mergeinfo" or "Modified:
svn:mergeinfo" shows up in the diff.

Recently one of my team members tried to rename a sub folder in a project
where there is a mergeinfo-property on the base folder.
He tried to do so using the command line client:

svn rename https://example.org/repo/project_a/subfolder_a
https://example.org/repo/project_a/subfolder_b

In this example, the "project_a" folder carries the mergeinfo property.

The commit hook complains that the operation is a merge an blocks (the user
did not use the word "merge" in the message since the operation is no merge
at all).

Doing the same rename in a working copy works.

I was not able to find any documentation on that behaviour: Obviously svn
copies the mergeinfo property from the root folder to the renamed folder -
but does only so if the rename is invoked as "svn rename from_url to_url".
If the rename is applied to a working copy and commited afterwards, the
svnlook on the server does not show adding the mergeinfo property.

I cannot imagine a case where copying the mergeinfo to the new folder is a
wanted behaviour, even worse, without the user being able to notice
anything about such an operation.

Maybe there's something wrong in our setup? Or is this the expected
behaviour?

The server currently uses httpd 2.2 + svn 1.8.13, the clients used for
testing where svn 1.8.13 and svn 1.9.7.

Any insight is appreciated!

Greetings

Nico
Received on 2017-11-06 18:10:48 CET

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.