My recipe for setting up Xmonad on Ubuntu GNU/Linux is here.
What is xmonad? Read this page to learn.
Some of these instructions were adapted from the Source Matters Blog. But I also depart from those instructions in certain ways.
First, download XQuartz. It's a replacement for the stock X11 utility that seems to work better with xmonad as far as TrueType fonts and keymappings are concerned.
Start up XQuartz, open Preferences.
- Under the Input tab, enable "Enable three button mouse" and "Option keys send Alt_L and Alt_R."
- Under the Output tab, set Colors to "millions". Don't select Full-Screen mode.
- Under the Pasteboard tab, enable all options.
- Under the Windows tab, I like choosing "Focus Follows Mouse."
Quit XQuartz.
For the following steps, you will need Homebrew. I'll assume you have it already.
Next brew install ghc haskell-platform
if you don't already have Haskell.
Next, install xmonad with cabal install xmonad
.
Create an ~/.xinitrc
file. This will be read when you start
XQuartz & launch xmonad immediately.
[[ -f ~/.Xresources ]] && xrdb -load ~/.Xresources
cd $HOME
xterm &
$HOME/.cabal/bin/xmonad
Create a ~/.Xdefaults
file. Put this in it:
xterm*Background: black
xterm*Foreground: green
xterm*cursorColor: purple
xterm*pointerShape: arrow
xterm*pointerColor: red
xterm*faceName: Monaco
xterm*faceSize: 9
Now restart XQuartz. You should be in xmonad. Press ALT+SHIFT+ENTER to open new window tiles. If xmonad seems unresponsive at first, click on the first xterm window to start capturing keyboard input.
You can change the colors, pointer, fontName and faceSize in .Xdefaults
. To see what
fonts you can choose from use this command: fc-list | less
.
To paste the contents of the pasteboard into an xmonad terminal, hold down OPTION and click the mouse/trackpad button.
To change font sizes for a particular window, you can use the popup xterm font menu, invoked with CTRL+COMMAND+click.
Hi, very helpful!
I found that out of the box, X11 xterm behaved very differently from iTerm.app. For example, the path would not be set correctly, and it would not respect the default shell set in iTerm with chsh. I found the solution to this, and committed it in my fork: https://gist.github.com/jbeard4/5898283/revisions