Closed 00-kat closed 2 months ago
before there was a toast inside satty... typically for GUI applications you would want some kind of information about the result of actions... I decided to remove the toast and add the notification especially in case "early-exit" is used - where the app would exit right away after successful action and the toast would not be read...
instead of adding a disable switch, maybe a post-action might also be an option ..?
before there was a toast inside satty... typically for GUI applications you would want some kind of information about the result of actions... I decided to remove the toast and add the notification especially in case "early-exit" is used - where the app would exit right away after successful action and the toast would not be read...
Ah, that makes a lot of sense.
instead of adding a disable switch, maybe a post-action might also be an option ..?
A post-action sounds cool in theory, but I can't think of how it could ever possibly be implemented. Would it be:
I can't see any use for either of these, and I'm not able to think of any other ways it could be implemented right now. For the first one, almost any operation could be done with the second one (for my examples, notify-send
, sh
and dex
work fine), since shells are quite powerful. For the second one, since satty is run from a shell, and since it already prints out the information (e.g. 'Copied to clipboard.') to stdout, pipes or command substitution would be a really simple way to do it, for example:
That notification
notify-send -i /usr/share/icons/hicolor/scalable/apps/satty.svg 'Satty' "$(grim - | satty -f -)"
Maybe you fancy dialog boxes
zenity --info --title Satty --icon satty --text "$(grim - | satty -f -)"
Automatically paste if copied (DON'T RUN IN A TERMINAL SINCE IT WILL PASTE BINARY DATA INTO YOUR TERMINAL, CRASHING IT)
if [ "$(grim - | satty -f -)" = 'Copied to clipboard.' ]; then wl-paste; fi
Open in gimp to edit (best used with autosave on copy option enabled)
grim - | satty -f - | awk -F "'" '{ print $2 }' | xargs -d'\n' gimp
Would love to see --disable-notifications
flag and disable-notifications
setting!
go ahead :)
When you copy (or save I think) a screenshot, a notification chimes in: Could there be an option (maybe
--disable-notification
) to disable the notification from showing?Also, may I ask why the notification exists in the first place? Since I feel like it would be incredibly easy to use
when you call it (from maybe a keybind or something) and to maybe even create a
satty
function that runsnotify-send
after if you use it from a shell.