diff --git a/img.sh b/img.sh index 420b2de..4ed7352 100755 --- a/img.sh +++ b/img.sh @@ -3,7 +3,7 @@ # Call with '-s' to target only a selection of the screen. clientid='3e7a4deb7ac67da' -img=$(date '+/tmp/%N.png') +img=$(mktemp '/tmp/img-XXXXXX.png') scrot -z "$@" $img >/dev/null 2>&1 || exit res=$(curl -sH "Authorization: Client-ID $clientid" -F "image=@$img" "https://api.imgur.com/3/upload")