2009-12-27 11:34:58 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
class Dwm <Formula
|
2010-07-27 21:44:57 +00:00
|
|
|
url 'http://dl.suckless.org/dwm/dwm-5.8.2.tar.gz'
|
2009-12-27 11:34:58 +00:00
|
|
|
homepage 'http://dwm.suckless.org/'
|
2010-07-27 21:44:57 +00:00
|
|
|
md5 'f0b422bfeaa812d66c6dd15c3cc92a6b'
|
2009-12-27 11:34:58 +00:00
|
|
|
head 'http://hg.suckless.org/dwm'
|
|
|
|
|
|
|
|
def install
|
2010-06-05 01:17:57 +00:00
|
|
|
# The dwm default quit keybinding Mod1-Shift-q collides with
|
2009-12-27 11:34:58 +00:00
|
|
|
# the Mac OS X Log Out shortcut in the Apple menu.
|
|
|
|
inreplace 'config.def.h',
|
|
|
|
'{ MODKEY|ShiftMask, XK_q, quit, {0} },',
|
|
|
|
'{ MODKEY|ControlMask, XK_q, quit, {0} },'
|
|
|
|
inreplace 'dwm.1', '.B Mod1\-Shift\-q', '.B Mod1\-Control\-q'
|
|
|
|
system "make PREFIX=#{prefix} install"
|
|
|
|
end
|
|
|
|
|
|
|
|
def caveats
|
2010-03-05 22:53:42 +00:00
|
|
|
<<-EOS
|
|
|
|
In order to use the Mac OS X command key for dwm commands,
|
2009-12-27 11:34:58 +00:00
|
|
|
change the X11 keyboard modifier map using xmodmap (1).
|
|
|
|
|
|
|
|
e.g. by running the following command from $HOME/.xinitrc
|
|
|
|
xmodmap -e 'remove Mod2 = Meta_L' -e 'add Mod1 = Meta_L'&
|
2010-06-05 01:17:57 +00:00
|
|
|
|
2010-11-10 18:16:28 +00:00
|
|
|
See also https://gist.github.com/311377 for a handful of tips and tricks
|
2010-06-05 01:17:57 +00:00
|
|
|
for running dwm on Mac OS X.
|
2010-03-05 22:53:42 +00:00
|
|
|
EOS
|
2009-12-27 11:34:58 +00:00
|
|
|
end
|
|
|
|
end
|