Skip to content

Instantly share code, notes, and snippets.

@nejni-marji
Created June 8, 2016 18:31
Show Gist options
  • Save nejni-marji/b0ebe295bbe57624b5e2ab40c5bcbb86 to your computer and use it in GitHub Desktop.
Save nejni-marji/b0ebe295bbe57624b5e2ab40c5bcbb86 to your computer and use it in GitHub Desktop.
#
# ~/.i3/config
#
set $mod Mod4
set $tree_meta g
set $mark_meta m
set $wksp_meta b
# startup
exec --no-startup-id ~/.i3/i3_startup.sh
floating_modifier $mod
font pango:Terminus 9
# colors border fill text split
# border fill text split
client.focused #600060 #800080 #ffffff #7fff7f
client.focused_inactive #202020 #404040 #ffffff #dfdfdf
client.unfocused #202020 #404040 #aaaaaa #dfdfdf
client.urgent #df5010 #ff7030 #ffffff #008fcf
# i3bar
bar {
status_command i3status
strip_workspace_numbers yes
tray_output primary
colors {
background #202020
statusline #c0c0c0
separator #ff7030
focused_workspace #600060 #800080 #ffffff
active_workspace #353535 #555555 #ffffff
inactive_workspace #000000 #202020 #aaaaaa
urgent_workspace #df5010 #ff7030 #ffffff
}
}
# keybinds
# i3 controls
bindsym $mod+Control+Shift+q exec "i3-nagbar -t warning -m 'exit i3?' -b 'yes' '~/.i3/i3exit.sh'"
bindsym $mod+Shift+c reload
bindsym $mod+Shift+r restart
# summon keys
bindsym $mod+Shift+Return exec i3-sensible-terminal
bindsym $mod+Return exec i3-sensible-terminal -e tmx
bindsym $mod+backslash exec dmenu_run -i -p run: -nb "#202020" -nf "#aaaaaa" -sb "#800080" -sf "#ffffff"
# special keys
bindsym XF86AudioPrev exec cmus-remote -r
bindsym XF86AudioPlay exec cmus-remote -u
bindsym XF86AudioNext exec cmus-remote -n
bindsym XF86AudioLowerVolume exec ~/bin/volctl -v -10
bindsym XF86AudioRaiseVolume exec ~/bin/volctl -v +10
bindsym XF86AudioMute exec ~/bin/volctl -m
bindsym Print exec "sh ~/bin/shot"
# container controls
bindsym $mod+Shift+q kill
# tree
bindsym $mod+$tree_meta focus parent
bindsym $mod+Shift+$tree_meta focus child
bindsym $mod+f fullscreen
bindsym $mod+s layout stacking
bindsym $mod+t layout tabbed
bindsym $mod+n layout toggle split
bindsym $mod+w split h
bindsym $mod+v split v
# floating
bindsym $mod+Shift+space floating toggle
bindsym $mod+space focus mode_toggle
# scratchpad
bindsym $mod+Shift+minus move scratchpad
bindsym $mod+minus scratchpad show
# focus container
bindsym $mod+h focus left
bindsym $mod+j focus down
bindsym $mod+k focus up
bindsym $mod+l focus right
bindsym $mod+Shift+h move left
bindsym $mod+Shift+j move down
bindsym $mod+Shift+k move up
bindsym $mod+Shift+l move right
# workspace
bindsym $mod+Control+Shift+$wksp_meta exec i3-input -P 'move workspace to output ' -F 'move workspace to output %s'
bindsym $mod+Control+$wksp_meta exec i3-input -P 'workspace ' -F 'workspace %s'
bindsym $mod+Shift+$wksp_meta exec i3-input -P 'move container to workspace ' -F 'move container to workspace %s'
bindsym $mod+$wksp_meta exec i3-input -P 'rename workspace to ' -F 'rename workspace to %s'
# marks
bindsym $mod+Control+Shiftt+$mark_meta exec i3-input -P 'unmark ' -F 'unmark %s'
bindsym $mod+Control+$mark_meta exec i3-input -P 'goto title ' -F '[title="%s"] focus'
bindsym $mod+Shift+$mark_meta exec i3-input -P 'mark ' -F 'mark %s'
bindsym $mod+$mark_meta exec i3-input -P 'goto mark ' -F '[con_mark="%s"] focus'
# focus workspace
bindsym $mod+1 workspace number $w1
bindsym $mod+2 workspace number $w2
bindsym $mod+3 workspace number $w3
bindsym $mod+4 workspace number $w4
bindsym $mod+5 workspace number $w5
bindsym $mod+6 workspace number $w6
bindsym $mod+7 workspace number $w7
bindsym $mod+8 workspace number $w8
bindsym $mod+9 workspace number $w9
bindsym $mod+0 workspace number $w0
# move container
bindsym $mod+Shift+1 move container to workspace number $w1
bindsym $mod+Shift+2 move container to workspace number $w2
bindsym $mod+Shift+3 move container to workspace number $w3
bindsym $mod+Shift+4 move container to workspace number $w4
bindsym $mod+Shift+5 move container to workspace number $w5
bindsym $mod+Shift+6 move container to workspace number $w6
bindsym $mod+Shift+7 move container to workspace number $w7
bindsym $mod+Shift+8 move container to workspace number $w8
bindsym $mod+Shift+9 move container to workspace number $w9
bindsym $mod+Shift+0 move container to workspace number $w0
# general settings
workspace_auto_back_and_forth yes
force_focus_wrapping yes
# workspace variables
set $w1 1:Web
set $w2 2:Misc
set $w3 3:Chat
set $w4 4:Media
set $w5 5:Gaming
set $w6 6
set $w7 7
set $w8 8
set $w9 9
set $w0 10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment