Make sure the output directory exists

This commit is contained in:
Fierelier 2022-08-25 11:06:24 +02:00
parent c304064437
commit ef2a5cf5a7

View File

@ -2,6 +2,7 @@
set -e
DIR="$HOME/Pictures/Screenshots"
FILE="$(date --utc "+%Y.%m.%d-%H.%M.%S").png"
mkdir -p "$DIR"
scrot --freeze --select "$DIR/$FILE"
xclip -selection clipboard -t image/png -i "$DIR/$FILE"
notify-send "wdvn-screenshot" "Saved. Copied image to clipboard." -t 2000 --icon="insert-image"