stupid screenshots

This commit is contained in:
Tristan 2023-04-18 08:58:39 +01:00
parent 04a6a50fbc
commit f98dbe041b
4 changed files with 15 additions and 14 deletions

View file

@ -35,6 +35,7 @@
imv
libsixel
swaybg
imagemagick
brave
logseq
@ -356,4 +357,12 @@
programs.librewolf.enable = true;
programs.git = {
enable = true;
aliases = {
graph = "log --oneline --all --graph";
amend = "commit --amend --no-edit";
};
};
}

View file

@ -1,9 +1,11 @@
#!/bin/sh
OUT_DIR=${GRIM_DEFAULT_DIR:-~/Pictures/Screenshots/}
OUT_DIR=${GRIM_DEFAULT_DIR:-~/Pictures/Screenshots}
mkdir -p "$OUT_DIR"
FILE=$OUT_DIR/$(date +"%Y-%m-%dT%H:%M:%SZ").png
grim -g "$(slurp -o)" - | wl-copy
notify-send "Screenshot Taken" "to the clipboard"
wl-paste > $OUT_DIR/$(date +"%Y-%m-%dT%H:%M:%SZ").png
grim -g "$(slurp -o)" "$FILE"
notify-send "Screenshot Taken" "$FILE"
cat "$FILE" | wl-copy -t image/png