Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add xmonad configuration

  • Loading branch information...
commit 18b617b444c70af8536f5c1f7fc5a3490e248eb5 1 parent fe496c7
@afeinberg authored
View
5 .gitignore
@@ -0,0 +1,5 @@
+*/xmonad-x86_64-linux
+*/xmonad.errors
+*/xmonad.hi
+*/xmonad.o
+
View
17 dot.xmonad/.xinitrc
@@ -0,0 +1,17 @@
+xsetroot -cursor_name left_ptr
+
+xscreensaver -no-splash &
+
+unclutter -idle 1 &
+
+tint2 -c ~/.xmonad/tint2rc &
+
+pidgin &
+
+nvidia-settings -l
+
+eval `ssh-agent -s`
+
+xmodmap ~/.xmodmaprc
+
+dbus-launch --exit-with-session xmonad
View
134 dot.xmonad/tint2rc
@@ -0,0 +1,134 @@
+#---------------------------------------------
+# TINT2 CONFIG FILE
+#---------------------------------------------
+
+#---------------------------------------------
+# BACKGROUND AND BORDER
+#---------------------------------------------
+rounded = 0
+border_width = 0
+background_color = #000000 60
+border_color = #ffffff 18
+
+rounded = 2
+border_width = 0
+background_color = #ffffff 40
+border_color = #ffffff 50
+
+rounded = 2
+border_width = 0
+background_color = #ffffff 18
+border_color = #ffffff 70
+
+#---------------------------------------------
+# PANEL
+#---------------------------------------------
+panel_monitor = all
+panel_position = top center
+panel_size = 100% 30
+panel_margin = 0 0
+panel_padding = 7 0
+font_shadow = 0
+panel_background_id = 1
+wm_menu = 0
+panel_dock = 1
+panel_layer = bottom
+
+#---------------------------------------------
+# TASKBAR
+#---------------------------------------------
+#taskbar_mode = multi_desktop
+taskbar_mode = single_desktop
+taskbar_padding = 2 3 2
+taskbar_background_id = 0
+#taskbar_active_background_id = 0
+
+#---------------------------------------------
+# TASKS
+#---------------------------------------------
+task_icon = 1
+task_text = 1
+task_maximum_size = 140 35
+task_centered = 1
+task_padding = 6 3
+task_font = sans 7
+task_font_color = #ffffff 70
+task_background_id = 3
+task_icon_asb = 100 0 0
+# replace STATUS by 'urgent', 'active' or 'iconfied'
+#task_STATUS_background_id = 2
+#task_STATUS_font_color = #ffffff 85
+#task_STATUS_icon_asb = 100 0 0
+# example:
+task_active_background_id = 2
+task_active_font_color = #ffffff 85
+task_active_icon_asb = 100 0 0
+urgent_nb_of_blink = 8
+
+#---------------------------------------------
+# SYSTRAYBAR
+#---------------------------------------------
+systray = 1
+systray_padding = 0 4 5
+systray_background_id = 0
+systray_sort = left2right
+systray_icon_size = 0
+systray_icon_asb = 100 0 0
+
+#---------------------------------------------
+# CLOCK
+#---------------------------------------------
+time1_format = %H:%M:%S
+time1_font = sans 8
+time2_format = %d %B
+time2_font = sans 6
+clock_font_color = #ffffff 76
+clock_padding = 1 0
+clock_background_id = 0
+#clock_lclick_command = xclock
+clock_rclick_command = orage
+#clock_tooltip = %A %d %B
+#time1_timezone = :US/Hawaii
+#time2_timezone = :Europe/Berlin
+#clock_tooltip_timezone = :/usr/share/zoneinfo/Europe/Paris
+
+#---------------------------------------------
+# BATTERY
+#---------------------------------------------
+battery = 0
+battery_hide = 98
+battery_low_status = 10
+battery_low_cmd = notify-send "battery low"
+bat1_font = sans 8
+bat2_font = sans 6
+battery_font_color = #ffffff 76
+battery_padding = 1 0
+battery_background_id = 0
+
+#---------------------------------------------
+# TOOLTIP
+#---------------------------------------------
+tooltip = 0
+tooltip_padding = 2 2
+tooltip_show_timeout = 0.7
+tooltip_hide_timeout = 0.3
+tooltip_background_id = 1
+tooltip_font_color = #OOOOOO 80
+tooltip_font = sans 10
+
+#---------------------------------------------
+# MOUSE ACTION ON TASK
+#---------------------------------------------
+mouse_middle = none
+mouse_right = close
+mouse_scroll_up = toggle
+mouse_scroll_down = iconify
+
+#---------------------------------------------
+# AUTOHIDE OPTIONS
+#---------------------------------------------
+autohide = 0
+autohide_show_timeout = 0.3
+autohide_hide_timeout = 2
+autohide_height = 4
+strut_policy = minimum
View
92 dot.xmonad/xmonad.hs
@@ -0,0 +1,92 @@
+{-------------------------------------------------------------------------------
+ Stolen from Chris P.
+-------------------------------------------------------------------------------}
+import XMonad
+import XMonad.Actions.WindowGo
+import XMonad.Hooks.DynamicLog
+import XMonad.Hooks.EwmhDesktops
+import XMonad.Hooks.ManageDocks
+import XMonad.Hooks.ManageHelpers
+import XMonad.Hooks.SetWMName
+import XMonad.Hooks.UrgencyHook
+import XMonad.Layout.Gaps
+import XMonad.Layout.NoBorders
+import XMonad.Layout.Spacing
+import XMonad.Util.EZConfig
+import XMonad.Util.Run
+import XMonad.Util.Scratchpad
+import System.IO
+
+{-------------------------------------------------------------------------------
+ Main
+-------------------------------------------------------------------------------}
+
+main = do
+ xmonad conf
+ {
+ startupHook = startupHook conf >> setWMName "LG3D"
+ }
+
+conf = withUrgencyHook NoUrgencyHook $ ewmh defaultConfig
+ { terminal = "urxvt"
+ , modMask = mod4Mask
+ , focusedBorderColor = "gray80"
+ , normalBorderColor = "gray20"
+ -- Shouldn't need gaps, but xmonad or tint2 are not respecting struts
+ , layoutHook = avoidStruts . smartBorders . gaps [(U,25)] $ layoutHook defaultConfig
+ , manageHook = manageHook defaultConfig <+> manageDocks
+ }
+ `removeKeysP` keysToRemove
+ `additionalKeysP` keysToAdd
+
+{-------------------------------------------------------------------------------
+ Key Bindings
+-------------------------------------------------------------------------------}
+
+-- Additional key bindings to add to the default configuration
+keysToAdd =
+ [ ("M-<Space>", spawn dmenuCmd)
+ , ("M-\\", sendMessage NextLayout)
+ , ("M-s", scratchpadSpawnActionTerminal "urxvt")
+ , ("M-f", runOrRaise "firefox" (className =? "Namoroka"))
+ , ("M-i", raiseMaybe (runInTerm "-title irssi" "sh -c 'irssi'") (title =? "irssi"))
+ , ("M-C-l", spawn "xscreensaver-command -lock")
+ , ("<XF86AudioMute>", spawn "amixer -q set Master toggle")
+ , ("<XF86AudioLowerVolume>", spawn "amixer -q set Master 2dB- unmute")
+ , ("<XF86AudioRaiseVolume>", spawn "amixer -q set Master 2dB+ unmute")
+ , ("<XF86AudioStop>", spawn "mpc stop")
+ , ("<XF86AudioPlay>", spawn "mpc toggle")
+ , ("<XF86AudioPrev>", spawn "mpc prev")
+ , ("<XF86AudioNext>", spawn "mpc next")
+ , ("<XF86ScreenSaver>", spawn "xscreensaver-command -l")
+ ]
+
+-- Key bindings to remove from the default configuration
+keysToRemove =
+ [ "M-p"
+ , "M-<Space>"
+ ]
+
+
+{-------------------------------------------------------------------------------
+ External Processes
+-------------------------------------------------------------------------------}
+
+dmenuCmd = "dmenu_run -fn " ++ quoteStr defaultFont
+
+
+{-------------------------------------------------------------------------------
+ Fonts
+-------------------------------------------------------------------------------}
+
+--defaultFont = terminusFont
+defaultFont = helveticaFont
+helveticaFont = "-*-helvetica-medium-r-*-*-12-*-*-*-*-*-*-*"
+--terminusFont = "-*-terminus-*-*-*-*-12-*-*-*-*-*-*-*"
+
+
+{-------------------------------------------------------------------------------
+ Helpers
+-------------------------------------------------------------------------------}
+
+quoteStr = wrap "'" "'"
View
1  setup.py
@@ -7,6 +7,7 @@
PATHS = dict({'dot.emacs':'${HOME}/.emacs',
'dot.vimrc':'${HOME}/.vimrc',
'dot.Xdefaults':'${HOME}/.Xdefaults',
+ 'dot.xmonad':'${HOME}/.xmonad',
'elisp':'${HOME}/elisp'})
def setup_paths():
Please sign in to comment.
Something went wrong with that request. Please try again.