Update zipline/flameshot.sh
This commit is contained in:
parent
ab41b066b0
commit
27304c4927
1 changed files with 2 additions and 0 deletions
|
@ -9,8 +9,10 @@ trap 'rm -f "$temp_file"' EXIT
|
|||
if curl -sS -fH "authorization: TOKEN" https://ZIPLINE_URL/api/upload -F file=@/tmp/ss.png -H "Content-Type: multipart/form-data" >"$temp_file" 2>&1; then
|
||||
link=$(jq -r '.files[0]' <"$temp_file" | tr -d '\n')
|
||||
echo "$link" | xsel -ib
|
||||
echo "Upload successful. Link copied to clipboard: $link"
|
||||
notify-send -a "Flameshot" -u low -i /tmp/ss.png -h "string:desktop-entry:org.flameshot.Flameshot" "Upload Successful" "Link copied to clipboard:\n$link"
|
||||
rm -f /tmp/ss.png
|
||||
else
|
||||
echo "Upload failed. Error message: $(<"$temp_file")"
|
||||
notify-send -a "Flameshot" -u critical -h "string:desktop-entry:org.flameshot.Flameshot" "Upload Failed" "$(<"$temp_file")"
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue