-
Notifications
You must be signed in to change notification settings - Fork 0
/
.skhdrc
123 lines (95 loc) · 5.3 KB
/
.skhdrc
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
# skhd config for Espen Ødegaard
# espenodegaard.com
# NOTE all built-in modifier and literal keywords can be found at https://github.com/koekeishiya/skhd/issues/1
# change focused window (including windows on next displays)
alt - h : yabai -m window --focus west || $(yabai -m display --focus west)
alt - j : yabai -m window --focus south || $(yabai -m display --focus south)
alt - k : yabai -m window --focus north || $(yabai -m display --focus north)
alt - l : yabai -m window --focus east || $(yabai -m display --focus east)
# swap windows
shift + ctrl - h : yabai -m window --swap west || $(yabai -m window --display west; yabai -m display --focus west)
shift + ctrl - j : yabai -m window --swap south || $(yabai -m window --display south; yabai -m display --focus south)
shift + ctrl - k : yabai -m window --swap north || $(yabai -m window --display north; yabai -m display --focus north)
shift + ctrl - l : yabai -m window --swap east || $(yabai -m window --display east; yabai -m display --focus east)
# warp windows (re-insert at other windows)
shift + alt - h : yabai -m window --warp west
shift + alt - j : yabai -m window --warp south
shift + alt - k : yabai -m window --warp north
shift + alt - l : yabai -m window --warp east
# resize windows
ctrl + alt - h : yabai -m window --resize left:-50:0; yabai -m window --resize right:-50:0
ctrl + alt - j : yabai -m window --resize bottom:0:50; yabai -m window --resize top:0:50
ctrl + alt - k : yabai -m window --resize top:0:-50; yabai -m window --resize bottom:0:-50
ctrl + alt - l : yabai -m window --resize right:50:0; yabai -m window --resize left:50:0
# (re)balance windows (after resized)
ctrl + alt - space : yabai -m space --balance
# toggle zoom-fullscreen
alt - f : yabai -m window --toggle zoom-fullscreen
# toggle float (or unfloat) on window -- center on screen
ctrl + alt + cmd - space : yabai -m window --toggle float --grid 5:5:1:1:3:3
shift + alt - t : yabai -m window --toggle float --grid 4:4:1:1:2:2 # remove this later, when I got the above "in my fingertips"
# toggle window split type
shift + ctrl - space : yabai -m window --toggle split
# rotate 270 (clockwise)
shift + alt - r : yabai -m space --rotate 270
# flip along y-axis
shift + alt - y : yabai -m space --mirror y-axis
# flip along x-axis
shift + alt - x : yabai -m space --mirror x-axis
# references only -- might (re)try later
# make floating window fill screen
# shift + alt - up : yabai -m window --grid 1:1:0:0:1:1
# make floating window fill left-half of screen
# shift + alt - left : yabai -m window --grid 1:2:0:0:1:1
# create desktop, move window and follow focus - uses jq for parsing json (brew install jq)
# shift + cmd - n : yabai -m space --create && \
# index="$(yabai -m query --spaces --display | jq 'map(select(."is-native-fullscreen" == false))[-1].index')" && \
# yabai -m window --space "${index}" && \
# yabai -m space --focus "${index}"
# fast focus desktop
# cmd + alt - x : yabai -m space --focus recent
# cmd + alt - 1 : yabai -m space --focus 1
# send window to desktop and follow focus
# shift + cmd - z : yabai -m window --space next; yabai -m space --focus next
# shift + cmd - 2 : yabai -m window --space 2; yabai -m space --focus 2
ctrl + cmd - 1 : yabai -m window --space 1; yabai -m space --focus 1
ctrl + cmd - 2 : yabai -m window --space 2; yabai -m space --focus 2
ctrl + cmd - 3 : yabai -m window --space 3; yabai -m space --focus 3
ctrl + cmd - 4 : yabai -m window --space 4; yabai -m space --focus 4
ctrl + cmd - 5 : yabai -m window --space 5; yabai -m space --focus 5
ctrl + cmd - 6 : yabai -m window --space 6; yabai -m space --focus 6
# focus monitor
# ctrl + alt - z : yabai -m display --focus prev
# ctrl + alt - 3 : yabai -m display --focus 3
# send window to monitor and follow focus
# ctrl + cmd - c : yabai -m window --display next; yabai -m display --focus next
# ctrl + cmd - 1 : yabai -m window --display 1; yabai -m display --focus 1
# move floating window
# shift + ctrl - a : yabai -m window --move rel:-18:0
# shift + ctrl - s : yabai -m window --move rel:0:20
# increase window size
# shift + alt - a : yabai -m window --resize left:-20:0
# shift + alt - w : yabai -m window --resize top:0:-20
# decrease window size
# shift + cmd - s : yabai -m window --resize bottom:0:-20
# shift + cmd - w : yabai -m window --resize top:0:20
# set insertion point in focused container
# ctrl + alt - h : yabai -m window --insert west
# toggle window zoom
# alt - d : yabai -m window --toggle zoom-parent
# alt - f : yabai -m window --toggle zoom-fullscreen
# toggle sticky(+float), picture-in-picture
# alt - p : yabai -m window --toggle sticky --toggle pip
# stop/start/restart yabai
# ctrl + alt - q : brew services stop yabai
# ctrl + alt - s : brew services start yabai
# ctrl + alt - r : brew services restart yabai
# move window to between workspaces
shift + alt - p : yabai -m window --space prev;
shift + alt - n : yabai -m window --space next;
# change focus between external displays (left and right)
# alt - s: yabai -m display --focus west
# alt - g: yabai -m display --focus east
# move window between displays -- i'm using swap across displays, hence rarely used
# shift + alt - s : yabai -m window --display west; yabai -m display --focus west;
# shift + alt - g : yabai -m window --display east; yabai -m display --focus east;