~emersion/dotfiles

dotfiles/.config/sway/config -rw-r--r-- 5.3 KiB
6c783d4dSimon Ser git: remove cookiefile 11 hours ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
# Logo key
set $mod Mod4
set $term termite
set $launcher dmenu_path | menu | xargs swaymsg exec

set $wallpaper /home/simon/.background
set $wallpaper_lock /home/simon/.background-lock
#set $lock swaylock -i `0x40`
set $lock swaylock -i $wallpaper

set $bg #000000
set $bga #444444
set $fg #ffffff
set $fgi #888888
set $fgu #555555
set $btf #000000

set $font_family DejaVu Sans Mono
set $font_size 11

default_orientation auto
floating_modifier $mod
default_border pixel
hide_edge_borders smart
smart_borders on

output * bg $wallpaper fill

bindsym $mod+Return exec $term
bindsym $mod+Shift+q kill
bindsym $mod+Space exec $launcher

bindsym $mod+Alt+c reload
bindsym $mod+Alt+q exit
bindsym $mod+Alt+p exec systemctl poweroff
bindsym $mod+Alt+s exec systemctl suspend

bindsym $mod+Left focus left
bindsym $mod+Down focus down
bindsym $mod+Up focus up
bindsym $mod+Right focus right

bindsym $mod+Shift+Left move left
bindsym $mod+Shift+Down move down
bindsym $mod+Shift+Up move up
bindsym $mod+Shift+Right move right

bindsym $mod+Ctrl+Left move workspace to output left
bindsym $mod+Ctrl+Right move workspace to output right

bindsym $mod+1 workspace 1
bindsym $mod+2 workspace 2
bindsym $mod+3 workspace 3
bindsym $mod+4 workspace 4
bindsym $mod+5 workspace 5
bindsym $mod+6 workspace 6
bindsym $mod+7 workspace 7
bindsym $mod+8 workspace 8
bindsym $mod+9 workspace 9
bindsym $mod+0 workspace 10

bindsym $mod+Shift+1 move container to workspace 1
bindsym $mod+Shift+2 move container to workspace 2
bindsym $mod+Shift+3 move container to workspace 3
bindsym $mod+Shift+4 move container to workspace 4
bindsym $mod+Shift+5 move container to workspace 5
bindsym $mod+Shift+6 move container to workspace 6
bindsym $mod+Shift+7 move container to workspace 7
bindsym $mod+Shift+8 move container to workspace 8
bindsym $mod+Shift+9 move container to workspace 9
bindsym $mod+Shift+0 move container to workspace 10

bindsym $mod+b splith
bindsym $mod+v splitv

bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed
bindsym $mod+e layout toggle split

bindsym $mod+Ctrl+f fullscreen

bindsym $mod+Shift+f floating toggle
bindsym $mod+f focus mode_toggle

bindsym $mod+a focus parent

# passwords
bindsym $mod+p exec passmenu $menu_args
# volume controls (special keys on keyboard)
bindsym --locked XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle
bindsym --locked XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5%
bindsym --locked XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5%
bindsym --locked XF86AudioMicMute exec pactl set-source-mute @DEFAULT_SOURCE@ toggle
# music controls (special keys on keyboard)
bindsym --locked XF86AudioNext exec playerctl next
bindsym --locked XF86AudioPlay exec playerctl play-pause
bindsym --locked XF86AudioPrev exec playerctl previous
bindsym --locked XF86AudioStop exec playerctl stop
# brightness controls
bindsym --locked XF86MonBrightnessDown exec brightnessctl set 5%-
bindsym --locked XF86MonBrightnessUp exec brightnessctl set 5%+
# lockscreen
# (sleep before entering idle state to let the user lift keys)
#bindsym --locked $mod+l exec "sleep 1; pkill -USR1 swayidle"
bindsym $mod+l exec "$lock -f; sleep 1; pkill -USR1 swayidle"
# screenshots
bindsym $mod+g exec grim
bindsym $mod+Shift+g exec slurp | grim -g -

bindsym XF86RFKill exec airplane-mode

bindsym $mod+n mode notifications
mode notifications {
	bindsym Escape mode default
	bindsym Return exec makoctl invoke; exec makoctl dismiss; mode default
	bindsym d exec makoctl dismiss; mode default
	bindsym Shift+d exec makoctl dismiss -a; mode default
}

bindsym $mod+r mode stewdio
mode stewdio {
	bindsym Escape mode default
	bindsym Space exec stewdio play
	bindsym s exec stewdio skip
	bindsym f exec stewdio fav
	bindsym q exec stewdio dmenu-queue
}

mode passthrough {
	bindsym $mod+Pause mode default
}
bindsym $mod+Pause mode passthrough

font pango:$font_family $font_size
# class                 border bg   text indicator child_border
client.focused          $bg    $bg  $fg  $bga      $bg
client.focused_inactive $bg    $bg  $fgi $bg       $bg
client.unfocused        $bg    $bg  $fgu $bg       $bg

bar {
	status_command i3status-rs
	position top
	font pango:$font_family, Font Awesome 5 Free $font_size
	separator_symbol ""
	colors {
		statusline $fg
		background $bg
		focused_background $bg
		focused_workspace $bg $bg $fg
		active_workspace $bg $bg $fg
		inactive_workspace $bg $bg $fgi
	}
	tray_output none
}

for_window [app_id="^menu$"] floating enable, border none
for_window [app_id=mpv] sticky enable
for_window [floating] border csd
for_window [app_id="firefox" title="Picture-in-Picture"] floating enable, sticky enable, border none
for_window [app_id="firefox" title="Firefox — Sharing Indicator"] kill

input type:keyboard {
	xkb_layout us
	xkb_variant altgr-intl
	xkb_options compose:ralt
}
input type:touchpad {
	natural_scroll enabled
	tap enabled
}

exec mako >/tmp/mako.log 2>&1
exec /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
exec kanshi >/tmp/kanshi.log 2>&1
exec poweralertd
exec check-disk-usage
exec swayidle -w \
	timeout 0 'swaymsg "output * dpms off"' \
	resume 'swaymsg "output * dpms on"' \
	before-sleep '$lock -f'

include ~/.config/sway/conf.d/*
include ~/.config/sway/"$(uname -n)"/*

exec systemctl --user import-environment DISPLAY WAYLAND_DISPLAY SWAYSOCK
exec dbus-update-activation-environment DISPLAY WAYLAND_DISPLAY SWAYSOCK
exec systemd-notify --ready