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

Issue with 'svn diff' when file name starts with @

From: Tim Van Holder <tim.vanholder_at_anubex.com>
Date: Mon, 29 Oct 2018 16:08:28 +0000

(I tried searching the issue tracker but it was extremely unresponsive; apologies if this is already in there (which seems likely))

Initially encountered on Windows (most recent TortoiseSVN).
Reproduced on Linux (Debian testing, subversion-1.10.3-1).

The help for svn diff suggests that it supports peg revisions (TARGET[@REV]).
However, this does not seem to be the case.

In fact, while most (all?) other svn commands will treat 'foo' and 'foo@' as equivalent file names, svn diff does not; 'svn diff foo@' (when only 'foo' exists) will result in E155010 (the node was not found).
(This seems part of SVN-3231.)

In addition, there is a significant bug in handling of file names starting with @; a diff for them can only be acquired by running 'svn diff' in their directory and using './<filename>'.
(I don't immediately see a ticket for this case.)

Reproduction case: create a new repo containing 2 files: foo/@bar and foo/xy_at_zzy
Check out the repository (messages below will assume it is in /wc):

$ cd /wc
$ svn diff foo/@bar
svn: E155010: The node '/wc/foo_at_bar' was not found.
$ svn diff foo/@bar@
svn: E155010: The node '/wc/foo_at_bar@' was not found.
$ svn diff foo/xy_at_zzy
$ svn diff foo/xy_at_zzy@
svn: E155010: The node '/wc/foo/xy_at_zzy@' was not found.
$ cd foo
$ svn diff @bar
svn: E125001: '@bar' is just a peg revision. Maybe try '@bar@' instead?
$ svn diff @bar@
svn: E155010: The node '/wc/foo/@bar' was not found.
$ svn diff ./@bar
$ svn diff ./@bar@
svn: E155010: The node '/wc/foo/@bar@' was not found.

So:

  * the normal 'append-_at_-to-avoid-peg-revision' syntax does not work (but in some cases the error message suggests using it)
  * files containing @ anywhere but at the start work fine
  * files with @ at the start seem to lose the directory separator in front of it, breaking diff operation
     * exception: using ./ as path while in the file's directory (so luckily this means I have a workaround)
Received on 2018-10-29 17:09:49 CET

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

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