feat: nixos - Screenshot Annotation via satty (#256)

Signed-off-by: Ryan Yin <xiaoyin_c@qq.com>
This commit is contained in:
Ryan Yin
2026-04-09 10:24:43 +08:00
committed by GitHub
parent 6cfc3c3154
commit 551020e0e8
2 changed files with 7 additions and 1 deletions

View File

@@ -232,7 +232,8 @@ binds {
// Mod+Space { switch-layout "next"; }
// Mod+Shift+Space { switch-layout "prev"; }
Print { screenshot; }
// Screenshot Annotation via satty
Print { spawn-sh "set -e; grim -t ppm -g \"$(slurp -o -d -F monospace)\" - | satty --filename - --copy-command=wl-copy --annotation-size-factor 2.0 --output-filename=\"$(xdg-user-dir PICTURES)/Screenshots/Screenshot from %Y-%m-%d %H:%M:%S.png\" --actions-on-enter=\"save-to-clipboard,exit\" --brush-smooth-history-size=5 --disable-notifications"; }
Ctrl+Print { screenshot-screen; }
Alt+Print { screenshot-window; }

View File

@@ -18,6 +18,11 @@ in
home.packages = with pkgs; [
# Niri v25.08 will create X11 sockets on disk, export $DISPLAY, and spawn `xwayland-satellite` on-demand when an X11 client connects
xwayland-satellite
# for Screenshot Annotation
slurp
grim
satty
];
xdg.configFile =