2008/3/8, Giovanni Bajo <[EMAIL PROTECTED]>: > > On Sat, 2008-03-08 at 15:28 +0100, Laurent PETIT wrote: > > > > > This is not required. It should be sufficient what svnmerge.py > > already > > does: > > > > # We expect non-localized output from SVN > > os.environ["LC_ALL"] = "C" > > > > You might want to try changing that into "LC_MESSAGES" to see > > if it > > makes any difference. > > > > > > Sorry, but I've the latest version of svnmerge.py from trunk, and I > > can't see the two above lines. > > You are right. It's been broken lately by this patch: > > ------------------------------------------------------------------------ > r29666 | rocketraman | 2008-03-02 01:48:59 +0100 (Sun, 02 Mar 2008) | 19 > lines > Changed paths: > M /trunk/contrib/client-side/svnmerge/svnmerge.py > M /trunk/contrib/client-side/svnmerge/svnmerge_test.py > > Resolve issue with encoding commit log messages as described by > Romulo Ceccon at: > > > http://article.gmane.org/gmane.comp.version-control.subversion.svnmerge.devel/872 > > * contrib/client-side/svnmerge.py: Import locale, set locale to user > default. > (recode_stdout_to_file): New method to decode standard output and > encode using > the user's default locale encoding. > (get_commit_log): Call recode_stdout_to_file to change the encoding of > svn > log output. > > * contrib/client-side/svnmerge_test.py > (testCommitMessageEncoding): New test case to verify the commit log > message > encoding. > > Patch by: Romulo A. Cesson <[EMAIL PROTECTED]> > me > Review by: Thomas Heller <[EMAIL PROTECTED]> > > ------------------------------------------------------------------------ > > I'm CC'ing the authors and reviewers. This patch contains this hunk: > > > ================================================================================ > @@ -89,8 +89,10 @@ > # Each line of the embedded log messages will be prefixed by > LOG_LINE_PREFIX. > LOG_LINE_PREFIX = 2 * ' ' > > -# We expect non-localized output from SVN > -os.environ["LC_ALL"] = "C" > +# Set python to the default locale as per environment settings, same as > svn > +# TODO we should really parse config and if log-encoding is specified, > set > +# the locale to match that encoding > +locale.setlocale(locale.LC_ALL, '') > > > > ############################################################################### > # Support for older Python versions > > ================================================================================ > > > which removes the LC_ALL=C from the environment. This is needed to force > SVN to produce non localized strings, as explained by the comment. Why > has it been removed?
Well, the comment at 29666 seems pretty clear. It refers to a previous discussion in this list: http://article.gmane.org/gmane.comp.version-control.subversion.svnmerge.devel/872 I don't know if the solution proposed is correct, but I can imagine that having a different encoding for the svn client running under svnmerge.py and running standalone might bring other problems. Of course, avoiding tildes or non-ascii letters in commit messages is a lot better than a non-working svnmerge at all. Anyway, I bet that sooner or later you'll come up with a solution that will satisfy everyone. Next Monday I'll "upgrade" to 29665 to have a suitable version for work. Giving that many (all?) people get their svnmerge.py right from the repository, it won't be a bad idea to make a quick patch just to make svnmerge.py work again under non-english OS. Thanks a lot for finding a solution in no time! Regards, -Hernan
_______________________________________________ Svnmerge mailing list [email protected] http://www.orcaware.com/mailman/listinfo/svnmerge
