My personal dotfiles
Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192
  1. #!/usr/bin/env bash
  2. # this is a simple config for herbstluftwm
  3. hc() {
  4. herbstclient "$@"
  5. }
  6. hc emit_hook reload
  7. xsetroot -solid '#5A8E3A'
  8. # remove all existing keybindings
  9. hc keyunbind --all
  10. # keybindings
  11. # if you have a super key you will be much happier with Mod set to Mod4
  12. #Mod=Mod1 # Use alt as the main modifier
  13. Mod=Mod4 # Use the super key as the main modifier
  14. hc keybind $Mod-Shift-Escape quit
  15. hc keybind $Mod-Shift-r reload
  16. hc keybind $Mod-Shift-q close
  17. hc keybind $Mod-Return spawn konsole
  18. # My bindings
  19. hc set default_frame_layout 1
  20. hc keybind $Mod-space spawn rofi -show combi
  21. hc keybind $Mod-backslash spawn emacs
  22. hc keybind $Mod-c spawn google-chrome-stable
  23. hc keybind XF86AudioRaiseVolume spawn amixer -D pulse sset Master 2%+
  24. hc keybind XF86AudioLowerVolume spawn amixer -D pulse sset Master 2%-
  25. hc keybind XF86AudioMute spawn amixer set Master toggle
  26. # basic movement
  27. # focusing clients
  28. hc keybind $Mod-Left focus left
  29. hc keybind $Mod-Down focus down
  30. hc keybind $Mod-Up focus up
  31. hc keybind $Mod-Right focus right
  32. hc keybind $Mod-h focus left
  33. hc keybind $Mod-j focus down
  34. hc keybind $Mod-k focus up
  35. hc keybind $Mod-l focus right
  36. # moving clients
  37. hc keybind $Mod-Shift-Left shift left
  38. hc keybind $Mod-Shift-Down shift down
  39. hc keybind $Mod-Shift-Up shift up
  40. hc keybind $Mod-Shift-Right shift right
  41. hc keybind $Mod-Shift-h shift left
  42. hc keybind $Mod-Shift-j shift down
  43. hc keybind $Mod-Shift-k shift up
  44. hc keybind $Mod-Shift-l shift right
  45. # splitting frames
  46. # create an empty frame at the specified direction
  47. hc keybind $Mod-u split bottom 0.5
  48. hc keybind $Mod-o split right 0.5
  49. # let the current frame explode into subframes
  50. hc keybind $Mod-Control-space split explode
  51. # resizing frames
  52. resizestep=0.05
  53. hc keybind $Mod-Control-h resize left +$resizestep
  54. hc keybind $Mod-Control-j resize down +$resizestep
  55. hc keybind $Mod-Control-k resize up +$resizestep
  56. hc keybind $Mod-Control-l resize right +$resizestep
  57. hc keybind $Mod-Control-Left resize left +$resizestep
  58. hc keybind $Mod-Control-Down resize down +$resizestep
  59. hc keybind $Mod-Control-Up resize up +$resizestep
  60. hc keybind $Mod-Control-Right resize right +$resizestep
  61. # tags
  62. tag_names=( {1..9} )
  63. tag_keys=( ampersand bracketleft braceleft braceright parenleft equal asterisk parenright plus )
  64. hc rename default "${tag_names[0]}" || true
  65. for i in ${!tag_names[@]} ; do
  66. hc add "${tag_names[$i]}"
  67. key="${tag_keys[$i]}"
  68. if ! [ -z "$key" ] ; then
  69. hc keybind "$Mod-$key" use_index "$i"
  70. hc keybind "$Mod-Shift-$key" move_index "$i"
  71. fi
  72. done
  73. # Since default wasn't setting properly for WS 1
  74. herbstclient load ${TAG_NAMES[0]} '(clients horizontal:1)'
  75. # cycle through tags
  76. hc keybind $Mod-period use_index +1 --skip-visible
  77. hc keybind $Mod-comma use_index -1 --skip-visible
  78. # layouting
  79. hc keybind $Mod-r remove
  80. hc keybind $Mod-s floating toggle
  81. hc keybind $Mod-f fullscreen toggle
  82. hc keybind $Mod-p pseudotile toggle
  83. # The following cycles through the available layouts within a frame, but skips
  84. # layouts, if the layout change wouldn't affect the actual window positions.
  85. # I.e. if there are two windows within a frame, the grid layout is skipped.
  86. hc keybind $Mod-Shift-space \
  87. or , and . compare tags.focus.curframe_wcount = 2 \
  88. . cycle_layout +1 vertical horizontal max vertical grid \
  89. , cycle_layout +1
  90. # mouse
  91. hc mouseunbind --all
  92. hc mousebind $Mod-Button1 move
  93. hc mousebind $Mod-Button2 zoom
  94. hc mousebind $Mod-Button3 resize
  95. hc set focus_follows_mouse 1
  96. # focus
  97. hc keybind $Mod-BackSpace cycle_monitor
  98. hc keybind $Mod-Tab cycle_all +1
  99. hc keybind $Mod-Shift-Tab cycle_all -1
  100. hc keybind $Mod-g cycle
  101. hc keybind $Mod-i jumpto urgent
  102. # theme
  103. hc attr theme.tiling.reset 1
  104. hc attr theme.floating.reset 1
  105. hc set frame_border_active_color '#222222'
  106. hc set frame_border_normal_color '#101010'
  107. #hc set frame_bg_normal_color '#565656'
  108. #hc set frame_bg_active_color '#345F0C'
  109. hc set frame_bg_normal_color '#000000'
  110. hc set frame_bg_active_color '#454545'
  111. hc set frame_border_width 1
  112. hc set always_show_frame 1
  113. hc set frame_bg_transparent 1
  114. hc set frame_transparent_width 5
  115. hc set frame_gap 4
  116. #hc attr theme.active.color '#9fbc00'
  117. #hc attr theme.normal.color '#454545'
  118. #hc attr theme.urgent.color orange
  119. hc attr theme.active.color '#6A8C8C'
  120. hc attr theme.normal.color '#000000'
  121. hc attr theme.urgent.color '#660000'
  122. hc attr theme.inner_width 1
  123. hc attr theme.inner_color black
  124. hc attr theme.border_width 3
  125. hc attr theme.floating.border_width 4
  126. hc attr theme.floating.outer_width 1
  127. hc attr theme.floating.outer_color black
  128. hc attr theme.active.inner_color '#3E4A00'
  129. hc attr theme.active.outer_color '#3E4A00'
  130. hc attr theme.background_color '#141414'
  131. hc set window_gap 0
  132. hc set frame_padding 0
  133. hc set smart_window_surroundings 0
  134. hc set smart_frame_surroundings 1
  135. hc set mouse_recenter_gap 0
  136. # rules
  137. hc unrule -F
  138. #hc rule class=XTerm tag=3 # move all xterms to tag 3
  139. hc rule focus=on # normally focus new clients
  140. #hc rule focus=off # normally do not focus new clients
  141. # give focus to most common terminals
  142. #hc rule class~'(.*[Rr]xvt.*|.*[Tt]erm|Konsole)' focus=on
  143. hc rule windowtype~'_NET_WM_WINDOW_TYPE_(DIALOG|UTILITY|SPLASH)' pseudotile=on
  144. hc rule windowtype='_NET_WM_WINDOW_TYPE_DIALOG' focus=on
  145. hc rule windowtype~'_NET_WM_WINDOW_TYPE_(NOTIFICATION|DOCK|DESKTOP)' manage=off
  146. hc set tree_style '╾│ ├└╼─┐'
  147. # Wallpaper
  148. feh --bg-scale ~/Pictures/calvin-and-hobbes-night-sky-wallpaper.jpg
  149. # unlock, just to be sure
  150. hc unlock
  151. # do multi monitor setup here, e.g.:
  152. # hc set_monitors 1280x1024+0+0 1280x1024+1280+0
  153. # or simply:
  154. # hc detect_monitors
  155. # find the panel
  156. panel=~/.config/herbstluftwm/panel.sh
  157. [ -x "$panel" ] || panel=/etc/xdg/herbstluftwm/panel.sh
  158. for monitor in $(herbstclient list_monitors | cut -d: -f1) ; do
  159. # start it on each monitor
  160. "$panel" $monitor &
  161. done
  162. feh --bg-center ~/Pictures/calvin-and-hobbes/bench.png