You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Evan Wee <ev...@nationalfibre.net> on 2012/02/22 23:10:06 UTC

SVN commit behaviour not consistent with other commands (such as delete or add)

Hi,

This may or may not be an issue, since it could be how the OS interprets the command. Explanation as follows.

Discovered an issue with running svn commit:

Merge is successful

[evanw@laptop] /Users/evanw/misc/rd/ 
=> svn merge http://svn/repo/tools/release_dashboard/trunk --dry-run
--- Merging r61477 through r61658 into '.':
D    jira.project.class.php
D    situationreport.class.php
D    report.class.php
D    situationreport.stage.class.php
D    jira.project.checkpoint.class.php
D    index.php
D    jira.class.php
[evanw@laptop] /Users/evanw/misc/rd/ 
=> svn merge http://svn/repo/tools/release_dashboard/trunk
--- Merging r61477 through r61658 into '.':
D    jira.project.class.php
D    report.class.php
D    situationreport.class.php
D    situationreport.stage.class.php
D    jira.project.checkpoint.class.php
D    index.php
D    jira.class.php
However, committing with * does not work:

[evanw@laptop] /Users/evanw/misc/rd/ 
=> svn ci * -m 'BM-123: merge from trunk into my branch'
Committing with . or the main directory name will work:

[evanw@laptop] /Users/evanw/misc/rd/ 
=> svn ci . -m 'BM-123: merge from trunk into my branch'
Sending        .
Deleting       index.php
Deleting       jira.class.php
Deleting       jira.project.checkpoint.class.php
Deleting       jira.project.class.php
Deleting       report.class.php
Deleting       situationreport.class.php
Deleting       situationreport.stage.class.php

Committed revision 61659.
Strangely, other commands with * used will work, such as svn delete, svn add, etc. Even svn commit * will work somewhat as it commits the modified and added files, but not the deleted ones.

I had a discussion with others and their explanation is that the character * refers to valid targets and thus deleted items are not targettable, hence their being missed in the commit. Should this be a valid exception case for svn commit so as to make it consistent with other svn commands?

Is this

Evan Wee
[Build]
Email/AIM: evanw@nationalfibre.net





Re: SVN commit behaviour not consistent with other commands (such as delete or add)

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Feb 22, 2012, at 16:10, Evan Wee wrote:

> However, committing with * does not work:

The asterisk is interpreted by your shell; Subversion has no opportunity to see that you typed an asterisk.


Re: SVN commit behaviour not consistent with other commands (such as delete or add)

Posted by Blair Zajac <bl...@orcaware.com>.
On 02/22/2012 02:20 PM, Konstantin Kolinko wrote:
> 2012/2/23 Evan Wee<ev...@nationalfibre.net>:
>>
>> Strangely, other commands with * used will work, such as svn delete, svn
>> add, etc. Even svn commit * will work somewhat as it commits the modified
>> and added files, but not the deleted ones.
>>
>> I had a discussion with others and their explanation is that the character *
>> refers to valid targets and thus deleted items are not targettable, hence
>> their being missed in the commit. Should this be a valid exception case for
>> svn commit so as to make it consistent with other svn commands?
>>
>
> The '*' filename pattern on Unixes is processed by the Shell before
> the command is passed to Subversion. It matches only existing files.
> Subversion cannot do anything with it.
>
> Officially - see
> http://pubs.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html
> Shell Command Language
> ->  2.6.6 Pathname Expansion

And even if this could be changed, you should just get in the practice 
of using . as a target instead, as if you do a merge and then 'svn 
commit *', you won't pick up the property change on the current working 
directory.  In other words, you would have committed everything but the 
metadata to record the merge.

Blair



Re: SVN commit behaviour not consistent with other commands (such as delete or add)

Posted by Konstantin Kolinko <kn...@gmail.com>.
2012/2/23 Evan Wee <ev...@nationalfibre.net>:
>
> Strangely, other commands with * used will work, such as svn delete, svn
> add, etc. Even svn commit * will work somewhat as it commits the modified
> and added files, but not the deleted ones.
>
> I had a discussion with others and their explanation is that the character *
> refers to valid targets and thus deleted items are not targettable, hence
> their being missed in the commit. Should this be a valid exception case for
> svn commit so as to make it consistent with other svn commands?
>

The '*' filename pattern on Unixes is processed by the Shell before
the command is passed to Subversion. It matches only existing files.
Subversion cannot do anything with it.

Officially - see
http://pubs.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html
Shell Command Language
-> 2.6.6 Pathname Expansion



Best regards,
Konstantin Kolinko