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

Re: svnlook Output Encoding

From: David E. Wheeler <david_at_kineticode.com>
Date: Thu, 21 Feb 2008 10:27:18 -0800

On Feb 20, 2008, at 23:11, Ryan Schmidt wrote:

> Set the LANG environment variable to a locale that your terminal
> supports and that contains the characters you want to output.

Thanks. I tried this:

* In my Mac OS X Terminal preferences, I set the character encoding to
latin-1.
* Tried it out locally with `svn log`:

LANG=en_US.ISO8859-1 svn log -r3448
------------------------------------------------------------------------
r3448 | theory | 2008-02-20 09:49:20 -0800 (Wed, 20 Feb 2008) | 2 lines

I think I can «eliminate» the `_encode()` and `_decode()` methods. So
let's see how things work with them doing nothing.

   So far so good.
* Then I ssh'd to my svn server running on FreeBSD 4.x and tried
`svnlook log`:

LC_ALL=en_US.ISO8859-1 LANG=en_US.ISO8859-1 /usr/local/bin/svnlook
log /usr/local/svnroot -r3448
I think I can ?\194?\171eliminate?\194?\187 the `_encode()` and
`_decode()` methods. So let's see how things work with them doing
nothing.

   Damn, it didn't work. This is in fact a valid locale on that BSD
system:

% ls -l /usr/share/nls | grep en_US
drwxr-xr-x 2 root wheel 512 Sep 18 2001 en_US.DIS_8859-15
drwxr-xr-x 2 root wheel 512 Jul 14 2003 en_US.ISO8859-1
drwxr-xr-x 2 root wheel 512 Jul 14 2003 en_US.ISO8859-15
lrwxrwxrwx 1 root wheel 15 Nov 8 2006 en_US.ISO_8859-1 ->
en_US.ISO8859-1
lrwxrwxrwx 1 root wheel 16 Nov 8 2006 en_US.ISO_8859-15 ->
en_US.ISO8859-15
lrwxrwxrwx 1 root wheel 1 Nov 8 2006 en_US.US-ASCII -> C

So that's a drag.

Is there no way at all to get `svnlook info` or `svnlook log` to just
output stuff in binary as I assume `svnlook diff` does?

Also, since I'm actually doing this from inside a Perl script that
runs as a post-commit hook, where the environment is pretty sparse,
it'd be nice to tell svnlook how to output stuff.

Thanks,

David
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-02-21 19:27:42 CET

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

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