Files
i3-themer/defaults.d/i3
T

78 lines
2.7 KiB
Bash

#!/bin/bash
# Put your own configuration here
# This file will be merged to the end of i3 config
# and will be ignored by git
function detectAudioMixer(){
if type "alsamixer" >/dev/null 2>/dev/null
then
echo "alsamixer"
else
echo "mixertui"
fi
}
function i3config(){
local mod='$mod'
local mode_gaps='$mode_gaps'
local mode_gaps_outer='$mode_gaps_outer'
local mode_gaps_inner='$mode_gaps_inner'
local mode_gaps_horiz='$mode_gaps_horiz'
local mode_gaps_verti='$mode_gaps_verti'
local mode_gaps_top='$mode_gaps_top'
local mode_gaps_right='$mode_gaps_right'
local mode_gaps_bottom='$mode_gaps_bottom'
local mode_gaps_left='$mode_gaps_left'
cat << EOF
focus_follows_mouse no
# User defined keys
bindsym Print exec i3-scrot -d
bindsym Shift+Print exec i3-scrot -s
bindsym Mod1+Sys_Req exec i3-scrot -w
bindsym $mod+F1 exec --no-startup-id i3-sensible-terminal -e $(detectAudioMixer)
bindsym $mod+F2 exec --no-startup-id sensible-browser
bindsym $mod+F3 exec --no-startup-id i3-sensible-terminal -e ranger
bindsym $mod+F4 exec --no-startup-id xcalc
bindsym $mod+F5 exec --no-startup-id i3-sensible-terminal -e cmus
bindsym $mod+F6 exec --no-startup-id i3-sensible-terminal -e neomutt
## Gaps
#gaps inner 10
#gaps outer -4
#smart_gaps on
## Press $mod+Shift+g to enter the gap mode. Choose o or i for modifying outer/inner gaps. Press one of + / - (in-/decrement for current workspace) or 0 (remove gaps for current workspace). If you also press Shift with these keys, the change will be global for all workspaces.
#set $mode_gaps Gaps: (o) outer, (i) inner
#set $mode_gaps_outer Outer Gaps: +|-|0 (local), Shift + +|-|0 (global)
#set $mode_gaps_inner Inner Gaps: +|-|0 (local), Shift + +|-|0 (global)
#bindsym $mod+Shift+g mode "$mode_gaps"
#mode "$mode_gaps" {
# bindsym o mode "$mode_gaps_outer"
# bindsym i mode "$mode_gaps_inner"
# bindsym Return mode "default"
# bindsym Escape mode "default"
#}
#mode "$mode_gaps_inner" {
# bindsym plus gaps inner current plus 5
# bindsym minus gaps inner current minus 5
# bindsym 0 gaps inner current set 0
# bindsym Shift+plus gaps inner all plus 5
# bindsym Shift+minus gaps inner all minus 5
# bindsym Shift+0 gaps inner all set 0
# bindsym Return mode "default"
# bindsym Escape mode "default"
#}
#mode "$mode_gaps_outer" {
# bindsym plus gaps outer current plus 5
# bindsym minus gaps outer current minus 5
# bindsym 0 gaps outer current set 0
# bindsym Shift+plus gaps outer all plus 5
# bindsym Shift+minus gaps outer all minus 5
# bindsym Shift+0 gaps outer all set 0
# bindsym Return mode "default"
# bindsym Escape mode "default"
#}
EOF
}