Utf8 unicode bash screen irssi

From TykWiki
Revision as of 09:39, 4 October 2012 by Tykling (talk | contribs)
Jump to navigationJump to search

Background

I am very fond of using irssi running in a screen as IRC client. I am on a wide range of IRC channels ranging from personal channels with friends to a bunch of opensource project channels. Some IRC channels I am in have a lot of UTF-8 unicode content, for example #musicbrainz on Freenode.

This page is how I remember what to configure to get UTF-8 working in irssi in screen on FreeBSD :)

Bash

First of all, the shell (of course). Bash needs to be sorted before anything else. If I cannot type in æøå into bash without weird sideeffects, I cannot expect it to work inside screen/irssi.

The following lines in ~/.bash_profile make bash behave properly with UTF-8:

export LC_ALL=da_DK.UTF-8
export LANG=da_DK.UTF-8

With a properly configured SSH client (see below), this is all I need to be able to enter Danish characters (or paste arabic or chinese UTF-8 text from wikipedia) into bash. Not that that in itself is very useful, but still :)

Screen / Irssi

I haven't touched my screen or irssi config to make this work. After bash got sorted it all just kindof worked.

Clients

PuTTy

When using PuTTy as SSH client I also go to Window -> Translation and set Received data assumed to be in which character set dropdown to UTF-8.