Re: git-svn dcommits messages not in UTF-8 charset to mod_dav_svn?
- From
- Eric Wong <normalperson@yhbt.net>
- Date
- May 28, 2009, 08:08 UTC
- Message-ID
- <20090528080706.GA9239@dcvr.yhbt.net>
- In-Reply-To
- <op.uuljhmmg1e62zd@balu.cs.uni-paderborn.de>
Matthias Andree <matthias.andree@gmx.de> wrote:
Show 13 quoted lines
> Greetings, > > I had tried to use git cvsimport and git svn to transfer a CVS repository > (I have access to it) to an SVN repository (where I don't have access to > the repo, so I cannot use cvs2svn or similar). > > The problem is that the CVS repo had non-UTF-8 commit log messages, and I > didn't bother to convert them to UTF-8. However, SVN insists on encoding > filenames and log messages in UTF-8. > > "git svn dcommit" (which uses the SVN Perl bindings under the hood) > happily committed such a non-UTF-8 message and br0ke the repo. The actual > reason is that the SVN server (https://...) is now wedged, as in:
Show 5 quoted lines
> While mod_dav_svn arguably shouldn't accept b0rked messages, git-svn > shouldn't attempt to commit them either. It seems that the svn command > line utilities validate the message format by themselves, and apparently > the svn server module (likely mod_dav_svn - or are there others?) does > not.
This was partially fixed in commit 16fc08e2d86dad152194829d21bc55b2ef0c8fb1. You just need to manually specify the i18n.commitencoding in your .git/config
> So, could > a) git-svn be modified to refuse dcommiting non-UTF-8 messages?
On the way is a patch that makes git-svn refuse to dcommit messages that are malformed UTF-8 and tell the user about i18n.commitencoding.
Thanks for reminding me
-- Eric Wong