A prettier Terminal in OS-X Part 1 (awesome is awesome!)

o I recently switched over to awesomewm on my desktop because either the desktop wm’s suck(kde,gnome) or fluxbox,fvwm weren’t quite what I needed.

So I went looking for a good terminal that supports 256 colors. There’s mrxvt and whatnot, but again the Probleme with these is that either utf-8 is missing or they’re in some other way ugly, dependency wise or whatever.

Then there’s this nifty term called urxvt(apparently it doesn’t seem to follow ecma-48?). Anyway, I like it and although iTerm does support 256 colors, it’s rather slow imho.

The end result could look like this…

The dependencies I used for installing awesome look as follows:

  • pango
  • imlib2
  • libconfuse
  • XQuartz ( at the time of this writing)

If you use macports 1.5 and XQuartz you should remove the cairo dependency from pango. Otherwise awesome might link to XQuartz cairo while pango links to macports cairo causing an annoying crash while restarting, connecting the second head or closing X11.

sudo perl -ni -e 'print unless /pkgconfig\/cairo/' /opt/local/var/macports/sources/rsync.macports.org/release/ports/x11/pango/Portfile

then you can probably do the following to install awesome(awesome.diff fixes a configure issue on osx, you can find it here ):

sudo port install pango imlib2 libconfuse

wget http://awesome.naquadah.org/download/awesome-2.3.4.tar.bz2
tar xjvf awesome-2.3.4.tar.bz2
cd awesome-2.3.4

patch -p1 < ../awesome.diff

./configure --prefix=/opt/local

The build will probably fail somewhere in between because of defconfig.h . If so you can use the following command to fix it:

# this can probably done much better but meh, i don't know sed syntax too well, -i '' means edit in place
sed -i '' -e 's/DEFAULT_CONFIG =.*$/DEFAULT_CONFIG = "\\/' -e 's/-n ".*$//' -e '/./!d' defconfig.h

Afterwards finishing the build you will probably want to create an ~/.xinitrc file and add the following to it:


#unless you want the annoying bells or visual bells keep the following 2 lines
xset b off 
xset b 0 0 0 

# the fork switch won't work on osx, so no -f here
export RXVT_SOCKET=$HOME/.rxvt_socket
urxvtd -q -o &


Also if you use an exotic shell config(eg. with zsh) it might break X11 a bit unless you put the following in your ~/.x11run


exec -l "bash" --login -c 'exec "${@}"' - "${@}"

Don’t forget to run

chmod +x ~/.x11run

afterwards(note this is a pretty new feature of XQuartz.

I’ll continue next time on how to setup urxvt. Meanwhile you can use xterm which also has 256 color support, however XQuartz xterm won’t detect terminus font if you decide to use a non antialiased font.

blog comments powered by Disqus
 Scroll to top