source: dotfiles/guix/rde/src/wkz-p1.scm@ 30cc41f

Last change on this file since 30cc41f was 30cc41f, checked in by Mikhail Kirillov <mikhail.kirillov@…>, on Apr 21, 2023 at 11:14:57 PM

Add brightness control to sway

  • Property mode set to 100644
File size: 5.6 KB
Line 
1(define-module (wkz-p1)
2 #:use-module (rde features)
3 #:use-module (rde features base)
4 #:use-module (rde features documentation)
5 #:use-module (rde features linux)
6 #:use-module (rde features networking)
7 #:use-module (rde features wm)
8 #:use-module (rde features finance)
9 #:use-module (rde features mail)
10 #:use-module (rde features irc)
11 #:use-module (rde features video)
12 #:use-module (rde features keyboard)
13 #:use-module (rde features fontutils)
14 #:use-module (rde features emacs)
15 #:use-module (rde features emacs-xyz)
16 #:use-module (rde features shellutils)
17 #:use-module (rde features terminals)
18 #:use-module (rde features shells)
19 #:use-module (rde features version-control)
20 #:use-module (rde features virtualization)
21 ;; #:use-module (rde features web)
22 #:use-module (rde features xdg)
23 #:use-module (gnu home-services base)
24 #:use-module (gnu home services)
25 #:use-module (gnu home-services wm)
26 #:use-module (gnu services)
27
28 #:use-module (rde packages)
29 #:use-module (guix gexp))
30
31(define home-extra-packages-service
32 (simple-service
33 'home-profile-extra-packages
34 home-profile-service-type
35 (append
36 (strings->packages
37 ;; "calibre"
38 "glibc-locales"
39 "icecat" ;; "nyxt"
40 ;; "ungoogled-chromium-wayland" "ublock-origin-chromium"
41
42 "alsa-utils" "yt-dlp" "cozy"
43 "pavucontrol" "wev"
44 "imagemagick"
45 "obs" "obs-wlrobs"
46 "recutils" "binutils" "make"
47
48 "papirus-icon-theme" "arc-theme"
49 "thunar" "fd"
50 "glib:bin"
51 "wob" "brightnessctl"
52
53 "ffmpeg"))))
54
55(define sway-extra-config-service
56 (simple-service
57 'sway-extra-config
58 home-sway-service-type
59 `((output DP-2 scale 2)
60 ,@(map (lambda (x) `(workspace ,x output DP-2)) (iota 8 1))
61
62 (bindswitch --reload --locked lid:on exec /run/setuid-programs/swaylock)
63
64 (bindsym --locked XF86MonBrightnessUp exec
65 ,(file-append (@ (gnu packages linux) brightnessctl) "/bin/brightnessctl")
66 set 5%+)
67 (bindsym --locked XF86MonBrightnessDown exec
68 ,(file-append (@ (gnu packages linux) brightnessctl) "/bin/brightnessctl")
69 set 5%-)
70
71 (bindsym
72 --locked $mod+Shift+t exec
73 ,(file-append (@ (gnu packages music) playerctl) "/bin/playerctl")
74 play-pause)
75
76 (bindsym
77 --locked $mod+Shift+n exec
78 ,(file-append (@ (gnu packages music) playerctl) "/bin/playerctl")
79 next)
80
81 (bindsym $mod+Shift+o move workspace to output left)
82 (bindsym $mod+Ctrl+o focus output left)
83 (input type:touchpad
84 ;; TODO: Move it to feature-sway or feature-mouse?
85 (;; (natural_scroll enabled)
86 (tap enabled)))
87
88 ;; (xwayland disable)
89 (bindsym $mod+Shift+Return exec emacs))))
90
91(define minimal-rde-config
92 (rde-config
93 (features
94 (list
95 ;; %general-features
96 (feature-user-info
97 #:user-name "w96k"
98 #:full-name "Mikhail Kirillov"
99 #:email "w96k.ru@gmail.com"
100 #:emacs-advanced-user? #t)
101
102 (feature-vterm)
103 (feature-bash)
104 (feature-direnv)
105
106 (feature-qemu)
107
108 (feature-base-services)
109 (feature-base-packages)
110
111 (feature-desktop-services)
112 (feature-hidpi)
113 (feature-foreign-distro)
114
115 (feature-sway)
116 (feature-emacs
117 #:default-application-launcher? #t)
118
119 (feature-keyboard
120 ;; To get all available options, layouts and variants run:
121 ;; cat `guix build xkeyboard-config`/share/X11/xkb/rules/evdev.lst
122 #:keyboard-layout
123 (keyboard-layout
124 "us,ru"
125 "qwerty"
126 #:options '("grp:shifts_toggle" "ctrl:nocaps")))
127
128 ;; (feature-alternative-frontends)
129
130 (feature-youtube-dl)
131
132 (feature-emacs-appearance)
133 ;; (feature-emacs-faces)
134 (feature-emacs-modus-themes)
135
136 (feature-emacs-completion
137 #:mini-frame? #f
138 #:marginalia-align 'right)
139 (feature-emacs-corfu
140 #:corfu-doc-auto #f)
141 (feature-emacs-vertico)
142
143 (feature-emacs-tramp)
144 (feature-emacs-project)
145 (feature-compile)
146 (feature-emacs-perspective)
147 (feature-emacs-input-methods)
148 (feature-emacs-which-key)
149 (feature-emacs-dired)
150 (feature-emacs-eshell)
151 (feature-emacs-monocle)
152
153 (feature-emacs-message)
154 ;; (feature-emacs-erc
155 ;; #:erc-log? #f
156 ;; #:erc-autojoin-channels-alist '((Libera.Chat "#rde")))
157 (feature-emacs-telega)
158 (feature-emacs-elpher)
159
160 (feature-emacs-pdf-tools)
161 ;; (feature-emacs-nov-el)
162 (feature-emacs-org)
163 (feature-emacs-org-roam
164 #:org-roam-directory "~/projects/at-w96k/content/digarden/pages/"
165 )
166 (feature-emacs-org-agenda)
167 (feature-emacs-org-protocol)
168 ;; TODO: Remove auctex dependency, which interjects in texinfo-mode.
169 ;; (feature-emacs-citar)
170
171 (feature-emacs-smartparens
172 #:show-smartparens? #t)
173
174 (feature-emacs-pulseaudio-control)
175 (feature-emacs-geiser)
176 (feature-emacs-guix)
177 (feature-emacs-eglot)
178
179 (feature-manpages)
180
181 (feature-xdg)
182
183 (feature-git #:sign-commits? #f)
184
185 (feature-custom-services
186 #:feature-name-prefix 'w96k
187 #:home-services
188 (list
189 home-extra-packages-service
190 sway-extra-config-service
191 ))
192
193 ;; (feature-mpv
194 ;; #:extra-mpv-conf '((speed . 1.61)))
195
196 (feature-sway-run-on-tty
197 #:sway-tty-number 2)
198 (feature-sway-screenshot)
199 ;; (feature-sway-statusbar
200 ;; #:use-global-fonts? #f)
201 (feature-waybar)
202 (feature-swayidle)
203 (feature-swaylock
204 #:swaylock (@ (gnu packages wm) swaylock-effects)
205 ;; The blur on lock screen is not privacy-friendly.
206 #:extra-config '((screenshots)
207 (effect-blur . 7x5)
208 (clock)))
209 ))))
210
211(rde-config-home-environment minimal-rde-config)
Note: See TracBrowser for help on using the repository browser.