[PATCH] Add description for SVNUseUTF8 (issue #2487)

Daniel Shahaf danielsh at elego.de
Thu Feb 2 14:46:33 CST 2012

Stefan Sperling wrote on Thu, Feb 02, 2012 at 21:37:53 +0100:
> On Thu, Feb 02, 2012 at 10:17:23PM +0200, Daniel Shahaf wrote:
> > So that people can use the hooks regardless of their SVNUseUTF8 setting.
> > 
> > I mean, I didn't invent the concept that people write hooks and publish
> > it for the world to use.  And such hooks need to be robust --- work with
> > a wide array of server configs.
> > 
> > (The book text implies that people may want to edit their hooks when
> > they enable SVNUseUTF8)
> It's trivial to add an environment variable to the hook's environment
> that reflects the value of the config option.
> But what do authors gain? Apart from assurance that they may write
> UTF-8 characters in error messages I don't see any advantage.

If repos_path, or an fspath argument, isn't ASCII, can hook scripts
access/use it even if the envvar isn't set?  (Or svnlook, when called
from such a hook script --- which I think you mentioned earlier.)

> Is this something we want to encourage?
> Currently no hook scripts do this because they won't work with
> mod_dav_svn if they do.
> If hook authors stick to ASCII for literal characters appearing in their
> scripts they are going to work with UTF-8. That's the entire point of UTF-8.

Dunno.  I suppose some people (the same people who build --enable-nls)
would be pleased to have non-ASCII error messages.  I could live without it.

> > I happen to know an httpd module that does that... :P
> But is also changes the entire httpd process locale,
> instead of just the character set available to a hook script.

More information about the svnbook-dev mailing list