summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2024-09-09 09:05:18 +0200
committerGregor Kleen <gkleen@yggdrasil.li>2024-09-09 09:05:18 +0200
commitdd2276099946a07e73c598d81ce0db35d93d71ea (patch)
treee217b2c2d76320dd31121c747fa1848bce3655ea
parent39ff9a59079e176ea1d76b08fec977f4d47c3682 (diff)
downloadnixos-dd2276099946a07e73c598d81ce0db35d93d71ea.tar
nixos-dd2276099946a07e73c598d81ce0db35d93d71ea.tar.gz
nixos-dd2276099946a07e73c598d81ce0db35d93d71ea.tar.bz2
nixos-dd2276099946a07e73c598d81ce0db35d93d71ea.tar.xz
nixos-dd2276099946a07e73c598d81ce0db35d93d71ea.zip
...
-rw-r--r--accounts/gkleen@sif/hyprland.nix24
-rw-r--r--user-profiles/mpv/default.nix3
2 files changed, 15 insertions, 12 deletions
diff --git a/accounts/gkleen@sif/hyprland.nix b/accounts/gkleen@sif/hyprland.nix
index 7cfd6848..17385a06 100644
--- a/accounts/gkleen@sif/hyprland.nix
+++ b/accounts/gkleen@sif/hyprland.nix
@@ -183,10 +183,10 @@ in {
183 "$mainMod SHIFT, code:15, movetoworkspacesilent, 9" 183 "$mainMod SHIFT, code:15, movetoworkspacesilent, 9"
184 "$mainMod SHIFT, code:16, movetoworkspacesilent, 10" 184 "$mainMod SHIFT, code:16, movetoworkspacesilent, 10"
185 185
186 "CTRL, space, exec, dunstctl close" 186 "$mainMod, semicolon, exec, dunstctl close"
187 "CTRL SHIFT, space, exec, dunstctl close-all" 187 "$mainMod SHIFT, semicolon, exec, dunstctl close-all"
188 "CTRL, period, exec, dunstctl context" 188 "$mainMod, period, exec, dunstctl context"
189 "CTRL, comma, exec, dunstctl history-pop" 189 "$mainMod, comma, exec, dunstctl history-pop"
190 190
191 "$mainMod ALT, E, exec, emacsclient -c" 191 "$mainMod ALT, E, exec, emacsclient -c"
192 "$mainMod ALT, Y, exec, ${pkgs.writeShellScript "yt-dlp" '' 192 "$mainMod ALT, Y, exec, ${pkgs.writeShellScript "yt-dlp" ''
@@ -194,13 +194,6 @@ in {
194 socat STDIO UNIX-CONNECT:"$XDG_RUNTIME_DIR"/yt-dlp.sock <<<$'{ "urls": ["'"$(wl-paste)"$'"] }' 194 socat STDIO UNIX-CONNECT:"$XDG_RUNTIME_DIR"/yt-dlp.sock <<<$'{ "urls": ["'"$(wl-paste)"$'"] }'
195 ''}" 195 ''}"
196 196
197 ", XF86MonBrightnessUp, exec, lightctl -d -e4 -n1 up"
198 ", XF86MonBrightnessDown, exec, lightctl -d -e4 -n1 down"
199 ", XF86AudioRaiseVolume, exec, volumectl -d -u up"
200 ", XF86AudioLowerVolume, exec, volumectl -d -u down"
201 ", XF86AudioMute, exec, volumectl -d toggle-mute"
202 ", XF86AudioMicMute, exec, volumectl -d -m toggle-mute"
203
204 ", Print, exec, ${pkgs.writeShellScript "screenshot" '' 197 ", Print, exec, ${pkgs.writeShellScript "screenshot" ''
205 export PATH="${lib.makeBinPath (with pkgs; [ grim slurp wl-clipboard-rs coreutils ])}:$PATH" 198 export PATH="${lib.makeBinPath (with pkgs; [ grim slurp wl-clipboard-rs coreutils ])}:$PATH"
206 199
@@ -339,7 +332,16 @@ in {
339 "$mainMod, mouse:272, movewindow" 332 "$mainMod, mouse:272, movewindow"
340 "$mainMod, mouse:273, resizewindow" 333 "$mainMod, mouse:273, resizewindow"
341 ]; 334 ];
335 bindel = [
336 ", XF86MonBrightnessUp, exec, lightctl -d -e4 -n1 up"
337 ", XF86MonBrightnessDown, exec, lightctl -d -e4 -n1 down"
338 ", XF86AudioRaiseVolume, exec, volumectl -d -u up"
339 ", XF86AudioLowerVolume, exec, volumectl -d -u down"
340 ];
342 bindl = [ 341 bindl = [
342 ", XF86AudioMute, exec, volumectl -d toggle-mute"
343 ", XF86AudioMicMute, exec, volumectl -d -m toggle-mute"
344
343 ", switch:off:Lid Switch,exec,hyprctl dispatch dpms on eDP-1" 345 ", switch:off:Lid Switch,exec,hyprctl dispatch dpms on eDP-1"
344 ", switch:on:Lid Switch,exec,hyprctl dispatch dpms off eDP-1" 346 ", switch:on:Lid Switch,exec,hyprctl dispatch dpms off eDP-1"
345 347
diff --git a/user-profiles/mpv/default.nix b/user-profiles/mpv/default.nix
index 8fc38edd..2df87994 100644
--- a/user-profiles/mpv/default.nix
+++ b/user-profiles/mpv/default.nix
@@ -91,7 +91,8 @@
91 mp.commandv('quit', '4') 91 mp.commandv('quit', '4')
92 end) 92 end)
93 mp.register_event('end-file', function(params) 93 mp.register_event('end-file', function(params)
94 if (params.reason == 'eof' or (do_del and params.reason == 'quit')) and del_path ~= ''' then 94 print('end-file: '..params.reason..', '..tostring(do_del)..', '..del_path)
95 if (params.reason == 'eof' or params.reason == 'stop' or (do_del and params.reason == 'quit')) and del_path ~= ''' then
95 print('deleting: '..del_path) 96 print('deleting: '..del_path)
96 os.remove(del_path) 97 os.remove(del_path)
97 end 98 end