-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathkarabiner.edn
107 lines (100 loc) · 4.28 KB
/
karabiner.edn
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
{:profiles
{:Default {:default true
:sim 10
:delay 80
:alone 200
:held 70}}
:tos {:same_wind_app {:key :grave_accent_and_tilde :modi [:left_command] :lazy true}
:left_paren {:key :9 :modi [:left_shift] :lazy true}
:right_paren {:key :0 :modi [:left_shift] :lazy true}}
:froms {:left_shift_alone {:key :left_shift :alone true}}
:applications {:chrome ["^com\\.google\\.Chrome$"]
:emacs-disabled ["^com\\.googlecode\\.iterm2$"
"^io\\.alacritty$"
"^org\\.alacritty$"
"^org\\.gnu\\.Emacs$"]
:firefox ["^org\\.mozilla\\.firefox$"]
:iterm ["^com\\.googlecode\\.iterm2$"]
:alacritty ["^io\\.alacritty$"
"^org\\.alacritty$"]
:bear ["^net\\.shinyfrog\\.bear$"]
:dbeaver ["^org\\.jkiss\\.dbeaver\\.core\\.product$"]
:onenote ["^com\\.microsoft\\.onenote\\.mac"]}
:devices {:wasd [{:vendor_id 1241 :product_id 321}]
:macbook-internal [{:vendor_id 1452 :product_id 631}, {:vendor_id 1452 :product_id 833}, {:device_id 4294969254}]
:magic [{:vendor_id 1452 :product_id 615}, {:vendor_id 76 :product_id 615}, {:vendor_id 1452 :product_id 638}]}
:templates {:open "open \"%s\""}
:simlayers {:launch-mode {:key :w}}
:main [{:des "caps to ctrl"
:rules [[:##caps_lock :left_control]]}
{:des "global emacs keys"
:rules [:!emacs-disabled
[:!T##b :left_arrow]
[:!T##p :up_arrow]
[:!T##n :down_arrow]
[:!T##f :right_arrow]
[:!T##m :return_or_enter]
[:!T##h :delete_or_backspace]]}
{:des "fn arrow key shortcuts"
:rules [[:!FSj :!Fleft_arrow]
[:!FSl :!Fright_arrow]
[:!F##j :left_arrow]
[:!F##i :up_arrow]
[:!F##k :down_arrow]
[:!F##l :right_arrow]]}
{:des "fn media key shortcuts"
:rules [[:!Fw :play_or_pause]
[:!Fq :rewind]
[:!Fe :fastforward]]}
{:des "ctrl-[ to esc"
:rules [[:!Topen_bracket :escape]]}
{:des "meta key"
:rules [:!emacs-disabled
[:!O#Sb :!Oleft_arrow]
[:!O#Sf :!Oright_arrow]
[:!Od :!Odelete_forward]
[:!Oh :!Odelete_or_backspace]]}
{:des "esc key on 60 key kb"
:rules [:wasd
[:##escape :##grave_accent_and_tilde]
[:!S##escape :!Sgrave_accent_and_tilde]
[:grave_accent_and_tilde :escape]]}
{:des "magic us keyboard"
:rules [[:##non_us_backslash :##grave_accent_and_tilde]
[:##grave_accent_and_tilde :##non_us_backslash]]}
{:des "cmd -> cmd+tab"
:rules [[:left_command :left_command nil {:alone :!Ctab}]
[:right_command :right_command nil {:alone :!Ctab}]]}
{:des "emacs keys in dbeaver"
:rules [:dbeaver :onenote
[:!T##a :!Cleft_arrow]
[:!T##e :!Cright_arrow]
[:!T##k [:!CSright_arrow :!Cx]]
[:!T##y :!Cv]]}
; TODO: Make this a toggle-able mode. Maybe move back to Ctrl-b as tmux prefix
{:des "iterm tmux"
:rules [:iterm :alacritty
; Tabs
[:!Ct [:!Tt :c]]
[:!CSd [:!Tt :s]]
[:!Cd [:!Tt :v]]
[:!CSopen_bracket [:!Tt :p]]
[:!CSclose_bracket [:!Tt :n]]
[:!C1 [:!Tt :1]]
[:!C2 [:!Tt :2]]
[:!C3 [:!Tt :3]]
[:!C4 [:!Tt :4]]
[:!C5 [:!Tt :5]]
[:!C6 [:!Tt :6]]
[:!C7 [:!Tt :7]]
[:!C8 [:!Tt :8]]
[:!C9 [:!Tt :9]]
[:!C0 [:!Tt :0]]
; Panes
[:!Cl [:!Tt :l]]
[:!Ch [:!Tt :h]]
[:!Ck [:!Tt :k]]
[:!Cj [:!Tt :j]]]}
]
:simlayer-threshold 210
:alone 120}