[BUG] git-svn fails to rename files with %20 in filename

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Someone accidentally checked some files containing "%20" in their names
into our svn repository, which is accessed with either svn or git-svn
depending on the developer.
When I attempted to correct this by renaming the file, I received (on
dcommit):
Filesystem has no item: File not found: revision 1, path
'/theBeginningOfTheOriginalFileName theRestOfTheOriginalFilename'
at /home/wpalmer/libexec/git-core/git-svn line 576


A recipe for reproducing this bug is as follows:
#!/bin/bash
temp="$(mktemp -t -d 'git-svn.XXXXXXXXXX')"
[ -n "$temp" ] || { echo "Failed to create temporary directory" >&2;
exit 1; }
function _cleanup(){
	rm -rf "$temp"
}
trap _cleanup INT EXIT
cd "$temp" || exit 1

set -x
svnadmin create svn-repos &&
svn co file://$PWD/svn-repos svn-wc &&
cd svn-wc &&
touch 'foo%20bar' &&
svn add 'foo%20bar' &&
svn ci -m 'add foo%20bar' &&
cd .. &&
git svn clone file://$PWD/svn-repos git-wc &&
cd git-wc &&
git mv 'foo%20bar' 'foo-bar' &&
git commit -m 's/%20/-/ in filename' &&
git svn dcommit # BUG HERE

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]