diff options
-rwxr-xr-x | upshot | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -2,9 +2,16 @@ set -e -file=$(mktemp --tmpdir screenshot-XXXX.png) +dir=$(mktemp --tmpdir -d) +trap "rm -rf '$dir'" EXIT INT TERM + +file=$(mktemp --tmpdir="$dir" screenshot-XXXX.png) maim -s "$file" +#flameshot gui -r > "$file" #gimp "$file" + +notify-send -t 5000 "Screenshot uploading" + if tty &>/dev/null && ! [[ $1 = "-n" ]]; then fb "$file" else @@ -12,4 +19,3 @@ else output=$(fb "$file") notify-send -t 5000 "Screenshot upload complete: $output" fi -rm "$file" |