You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Tobias Bading <tb...@web.de> on 2019/07/30 13:40:08 UTC
Subversion 1.12.2: "svn diff --changelist ARG" broken in subdirectories?
Hi.
I just built Subversion 1.12.2 on GNU/Linux and "make check" didn't show any problems.
But in this version, "svn diff --changelist ARG" only works in the root of a working copy. In any subdirectory of the working copy, there's no output at all.
Here's a little shell script that reproduces the problem:
--- %< ---
#!/bin/sh
##############################################################################
## ##
## Script to reproduce a bug where "svn diff --changelist ABC" shows ##
## nothing when executed in a subdirectory of a working copy root. ##
## ##
##############################################################################
SVN=`which svn`
SVNADMIN=`which svnadmin`
URL=file:///`pwd`/test-repo
rm -rf test-repo test-repo-wc
echo ""
echo "### Creating empty test repository..."
${SVNADMIN} create test-repo
echo ""
echo "### Checking out working copy of empty repository..."
${SVN} co -q ${URL} test-repo-wc
echo ""
echo "### Creating/adding file subdir/abc.txt in working copy..."
mkdir test-repo-wc/subdir
echo "This sucks." > test-repo-wc/subdir/abc.txt
${SVN} add --parents test-repo-wc/subdir/abc.txt
echo ""
echo "### Committing changes to repository..."
${SVN} ci -m "file added" test-repo-wc
echo ""
echo "### Adding file to changelist test..."
${SVN} changelist test test-repo-wc/subdir/abc.txt
echo ""
echo "### Adding line to file..."
echo 'It does.' >> test-repo-wc/subdir/abc.txt
echo ""
echo '### Output of "svn diff --changelist test" in root of working copy:'
( cd test-repo-wc ; ${SVN} diff --changelist test )
echo ""
echo '### Output of "svn diff --changelist test" in directory subdir:'
echo "### (except for the path name, this diff should be identical to the previous,"
echo " but there is no output at all in Subversion 1.12.2)"
( cd test-repo-wc/subdir ; ${SVN} diff --changelist test )
echo ""
--- >% ---
The last diff has no output. This script works fine with Subversion 1.10.6.
Is anyone able to reproduce this?
Thanks,
Tobias
PS: I'm not subscribed to the mailing list, so please keep me CC'd.
SVN-4822: "svn diff --changelist ARG" broken in subdirectories?
Posted by Julian Foad <ju...@apache.org>.
Tobias Bading wrote:
> "svn diff --changelist ARG" only works in the root of a working copy.
> In any subdirectory of the working copy, there's no output at all.
Thank you for reporting it and the test case. Yes, I noticed this
recently, and I think it's likely that I broke it, so I'll try to fix it.
So I have filed it as issue #4822 and added that to the email subject.
- Julian
Re: Subversion 1.12.2: "svn diff --changelist ARG" broken in subdirectories?
Posted by Tobias Bading <tb...@web.de>.
Hi Julian,
thanks for your patch.
Merging r1865841 into branch /subversion/branches/1.12.x (@1866070) works fine, including "make check" passing your new test case.
Regards,
Tobias
> On 30.08.2019 17:22, Julian Foad wrote:
> [ https://subversion.apache.org/issue/4822 ]
>
> Fixed in http://svn.apache.org/r1865841 . May be backported to 1.12.x; will anyway be released in 1.13.0.
>
> - Julian
Re: Subversion 1.12.2: "svn diff --changelist ARG" broken in
subdirectories?
Posted by Julian Foad <ju...@apache.org>.
[ https://subversion.apache.org/issue/4822 ]
Fixed in http://svn.apache.org/r1865841 . May be backported to 1.12.x;
will anyway be released in 1.13.0.
- Julian
Re: Subversion 1.12.2: "svn diff --changelist ARG" broken in subdirectories?
Posted by Nathan Hartman <ha...@gmail.com>.
On Tue, Jul 30, 2019 at 9:40 AM Tobias Bading <tb...@web.de> wrote:
> Hi.
>
> I just built Subversion 1.12.2 on GNU/Linux and "make check" didn't show
> any problems.
> But in this version, "svn diff --changelist ARG" only works in the root of
> a working copy. In any subdirectory of the working copy, there's no output
> at all.
>
I can confirm that the outcome on my system is exactly as you
describe.
svn diff --changelist ARG appears to work only in the root of a
working copy, not in a subdirectory.
When run in a subdirectory there is no output, even though the file
has changed.
FYI I did not run your reproduction script but I did perform similar
actions on one of my working copies and I can confirm.
I am using Subversion 1.12.2 which I likewise built and installed from
source a couple of days ago. There were no problems in make check.
Not that it appears to make any difference but my platform: Debian 9.9
"Stretch" and svn version: 1.12.2 (r1863366).
The rest of your email with reproduction script follows. I'm
preserving it because it has been a couple of weeks since you
wrote:
Here's a little shell script that reproduces the problem:
>
> --- %< ---
>
> #!/bin/sh
>
>
> ##############################################################################
> ##
> ##
> ## Script to reproduce a bug where "svn diff --changelist ABC" shows
> ##
> ## nothing when executed in a subdirectory of a working copy root.
> ##
> ##
> ##
>
> ##############################################################################
>
> SVN=`which svn`
> SVNADMIN=`which svnadmin`
>
> URL=file:///`pwd`/test-repo
>
> rm -rf test-repo test-repo-wc
>
> echo ""
> echo "### Creating empty test repository..."
> ${SVNADMIN} create test-repo
> echo ""
>
> echo "### Checking out working copy of empty repository..."
> ${SVN} co -q ${URL} test-repo-wc
> echo ""
>
> echo "### Creating/adding file subdir/abc.txt in working copy..."
> mkdir test-repo-wc/subdir
> echo "This sucks." > test-repo-wc/subdir/abc.txt
> ${SVN} add --parents test-repo-wc/subdir/abc.txt
> echo ""
>
> echo "### Committing changes to repository..."
> ${SVN} ci -m "file added" test-repo-wc
> echo ""
>
> echo "### Adding file to changelist test..."
> ${SVN} changelist test test-repo-wc/subdir/abc.txt
> echo ""
>
> echo "### Adding line to file..."
> echo 'It does.' >> test-repo-wc/subdir/abc.txt
> echo ""
>
> echo '### Output of "svn diff --changelist test" in root of working copy:'
> ( cd test-repo-wc ; ${SVN} diff --changelist test )
> echo ""
>
> echo '### Output of "svn diff --changelist test" in directory subdir:'
> echo "### (except for the path name, this diff should be identical to the
> previous,"
> echo " but there is no output at all in Subversion 1.12.2)"
> ( cd test-repo-wc/subdir ; ${SVN} diff --changelist test )
> echo ""
>
> --- >% ---
>
> The last diff has no output. This script works fine with Subversion 1.10.6.
>
> Is anyone able to reproduce this?
>
> Thanks,
> Tobias
>
> PS: I'm not subscribed to the mailing list, so please keep me CC'd.
>
>
>