blob: 63da2750d3c63366accced2bc7d7fa787a833f37 (
about) (
plain)
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
|
(in-package :stumpwm)
(which-key-mode)
(setf *mouse-focus-policy* :click)
;; prefix key
(set-prefix-key (kbd "C-t"))
;; prompt the user for an interactive command. The first arg is an
;; optional initial contents.
(defcommand colon1 (&optional (initial "")) (:rest)
(let ((cmd (read-one-line (current-screen) ": " :initial-input initial)))
(when cmd
(eval-command cmd t))))
;; Run rofi
(define-key *root-map* (kbd "C-r") "exec rofi -show drun")
(define-key *root-map* (kbd "e") "exec emacsclient -c")
;; Browse somewhere
(define-key *root-map* (kbd "b") "colon1 exec firefox http://www.")
;; Lock screen
(define-key *root-map* (kbd "C-l") "exec xlock")
;; Audio
(define-key *top-map* (kbd "XF86AudioLowerVolume") "exec amixer sset Master 5%-")
(define-key *top-map* (kbd "XF86AudioRaiseVolume") "exec amixer sset Master 5%+")
;;Keyboard-light
(define-key *top-map* (kbd "XF86Explorer") "exec brightnessctl --device='tpacpi::kbd_backlight' set +1")
(define-key *top-map* (kbd "XF86LaunchA") "exec brightnessctl --device='tpacpi::kbd_backlight' set 1-")
(define-key *top-map* (kbd "") "exec amixer sset Master 5%+")
;;; Groups
;; Switch to group
(define-key *top-map* (kbd "s-1") "gselect 1")
(define-key *top-map* (kbd "s-2") "gselect 2")
(define-key *top-map* (kbd "s-3") "gselect 3")
(define-key *top-map* (kbd "s-4") "gselect 4")
(define-key *top-map* (kbd "s-5") "gselect 5")
(define-key *top-map* (kbd "s-6") "gselect 6")
(define-key *top-map* (kbd "s-7") "gselect 7")
;; Move window to group
(define-key *top-map* (kbd "s-!") "gmove 1")
(define-key *top-map* (kbd "s-@") "gmove 2")
(define-key *top-map* (kbd "s-#") "gmove 3")
(define-key *top-map* (kbd "s-$") "gmove 4")
(define-key *top-map* (kbd "s-%") "gmove 5")
(define-key *top-map* (kbd "s-^") "gmove 6")
(define-key *top-map* (kbd "s-&") "gmove 7")
;; Focus
(define-key *top-map* (kbd "s-b") "move-focus left")
(define-key *top-map* (kbd "s-f") "move-focus right")
(define-key *top-map* (kbd "s-n") "move-focus down")
|