subatom 0.10

I’ve made another release of subatom. This contains a number of fixes for bugs that I managed to put into the 0.09 release (as well as a couple of minor features). This has really left me with a very nagging need for some tests for this module.

  • Restore the ability to send output to stdout.
  • Make the command line mode work, as well as the config file.
  • Don’t cover up stderr when executing “svn log”.
  • Force subversion to give us back UTF-8, and cope with it.
  • Add support for using—limit if your svn has it.

That item about UTF-8 has annoyed me, because it’s brought me into contact with a hated topic: locales.

Subversion internally works with UTF-8 everywhere. This is a sensible design. But in order to interface with the outside world, it needs to convert that into whatever character encoding you are using. How does it know what character encoding to use? It guesses from the locale.

The locale is meant to be a specification for how to sort characters, how to format the date and so on and so forth. In recent years, it’s also been taken over to specify the character encoding that’s in use. So, to specify that I want to see the world in UTF-8, I need to say:

  export LC_ALL=en_GB.UTF-8

Except that breaks ls(1). Yes, ls(1). For some insane reason, setting a locale changes the way that things work such sorting now happens in a case-independent manner. So that “README” files no longer appear at the top of a directory listing. I haven’t investigated any further to see what else is broken. I quickly switched back to the “C” locale, which effectively means no locale.

So now, I’m left wondering how to tell the system that I’d like UTF-8, but none of the other inconveniences that locales bring me.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s