mirror of
https://github.com/alyraffauf/nixcfg.git
synced 2024-11-24 09:12:27 -05:00
home/desktop: simplify screenshoot bindings
This commit is contained in:
parent
6b1be071f6
commit
5687e919f9
|
@ -34,8 +34,7 @@
|
||||||
|
|
||||||
### Screenshots
|
### Screenshots
|
||||||
|
|
||||||
- PRINT // CTRL + F12: Take screenshot of monitor.
|
- PRINT // CTRL + F12: Take screenshot of monitor or selected area.
|
||||||
- SUPER + PRINT // SUPER CTRL + F12: Take screenshot of selected area.
|
|
||||||
|
|
||||||
### Session Control
|
### Session Control
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,6 @@ in {
|
||||||
|
|
||||||
bind =
|
bind =
|
||||||
[
|
[
|
||||||
"$mod CONTROL,F12,exec,${helpers.screenshot.region}"
|
|
||||||
"$mod CONTROL,L,exec,${lib.getExe pkgs.swaylock}"
|
"$mod CONTROL,L,exec,${lib.getExe pkgs.swaylock}"
|
||||||
"$mod SHIFT,S,movetoworkspace,special:magic"
|
"$mod SHIFT,S,movetoworkspace,special:magic"
|
||||||
"$mod SHIFT,V,togglefloating"
|
"$mod SHIFT,V,togglefloating"
|
||||||
|
@ -41,7 +40,6 @@ in {
|
||||||
"$mod,F,exec,${lib.getExe cfg.defaultApps.fileManager}"
|
"$mod,F,exec,${lib.getExe cfg.defaultApps.fileManager}"
|
||||||
"$mod,F11,exec,pkill -SIGUSR1 waybar"
|
"$mod,F11,exec,pkill -SIGUSR1 waybar"
|
||||||
"$mod,M,exec,${lib.getExe pkgs.wlogout}"
|
"$mod,M,exec,${lib.getExe pkgs.wlogout}"
|
||||||
"$mod,PRINT,exec,${helpers.screenshot.region}"
|
|
||||||
"$mod,R,exec,${lib.getExe pkgs.fuzzel}"
|
"$mod,R,exec,${lib.getExe pkgs.fuzzel}"
|
||||||
"$mod,S,togglespecialworkspace,magic"
|
"$mod,S,togglespecialworkspace,magic"
|
||||||
"$mod,T,exec,${lib.getExe cfg.defaultApps.terminal}"
|
"$mod,T,exec,${lib.getExe cfg.defaultApps.terminal}"
|
||||||
|
@ -49,8 +47,8 @@ in {
|
||||||
"$mod,mouse_down,workspace,+1"
|
"$mod,mouse_down,workspace,+1"
|
||||||
"$mod,mouse_up,workspace,-1"
|
"$mod,mouse_up,workspace,-1"
|
||||||
"$mod,period,exec,${lib.getExe pkgs.hyprnome}"
|
"$mod,period,exec,${lib.getExe pkgs.hyprnome}"
|
||||||
",PRINT,exec,${helpers.screenshot.screen}"
|
",PRINT,exec,${helpers.screenshot}"
|
||||||
"CONTROL,F12,exec,${helpers.screenshot.screen}"
|
"CONTROL,F12,exec,${helpers.screenshot}"
|
||||||
"CTRL ALT,M,submap,move"
|
"CTRL ALT,M,submap,move"
|
||||||
"CTRL ALT,R,submap,resize"
|
"CTRL ALT,R,submap,resize"
|
||||||
]
|
]
|
||||||
|
|
|
@ -18,8 +18,7 @@
|
||||||
prev = "${bin} previous";
|
prev = "${bin} previous";
|
||||||
};
|
};
|
||||||
|
|
||||||
screenshot = rec {
|
screenshot = pkgs.writeShellScript "screenshooter" ''
|
||||||
bin = pkgs.writeShellScript "screenshooter" ''
|
|
||||||
FILENAME=${config.xdg.userDirs.pictures}/screenshots/$(date +'%Y-%m-%d-%H:%M:%S_grim.png')
|
FILENAME=${config.xdg.userDirs.pictures}/screenshots/$(date +'%Y-%m-%d-%H:%M:%S_grim.png')
|
||||||
MAKO_MODE=$(${lib.getExe' pkgs.mako "makoctl"} mode)
|
MAKO_MODE=$(${lib.getExe' pkgs.mako "makoctl"} mode)
|
||||||
|
|
||||||
|
@ -42,10 +41,6 @@
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|
||||||
region = "${bin}";
|
|
||||||
screen = "${bin}";
|
|
||||||
};
|
|
||||||
|
|
||||||
volume = rec {
|
volume = rec {
|
||||||
bin = lib.getExe' pkgs.swayosd "swayosd-client";
|
bin = lib.getExe' pkgs.swayosd "swayosd-client";
|
||||||
up = "${bin} --output-volume=raise";
|
up = "${bin} --output-volume=raise";
|
||||||
|
|
Loading…
Reference in a new issue