notification control

Signed-off-by: fbt <fbt@fleshless.org>
This commit is contained in:
Jack L. Frost 2019-11-22 14:43:04 +03:00
parent d73f41e2de
commit 99735444f3

8
ufw
View File

@ -33,6 +33,8 @@ usage() {
-d|--description # Supply a description.
-D|--screenshot-delay <num> # Delay the shot by <num> seconds.
-p|--public # Make the file public.
-n|--no-notify # Don't send immediate notifications for this upload.
--notify # Force a notification for this upload.
-u|--shorten <URL> # Generate a shortlink from URL.
-S|--short-url # Get a shortlink when uploading a file.
-P|--page-url # Get a link to the file page instead of a direct one.
@ -142,6 +144,7 @@ upload() {
-F flag_private="$flag_private" \
-F secret="$secret" \
-F tags="$tags" \
-F notify="$flag_notify" \
-F submit="" \
"${misc_curl_args[@]}" \
-A 'zerofiles.org upload script' \
@ -306,7 +309,7 @@ set_argv() {
}
main() {
declare args file target flag_private flag_rm flag_scn flag_scn_fullscreen cfg_scn_delay
declare args file target flag_private flag_rm flag_scn flag_scn_fullscreen cfg_scn_delay flag_notify
declare flag_shortlink=0
# Defaults for XDG
@ -358,6 +361,9 @@ main() {
-P|--page-url) flag_directlink=0;;
-q|--quiet) flag_quiet=1;;
--notify) flag_notify=1;;
--no-notify|-n) flag_notify=0;;
-F|--fullscreen)
flag_scn='1'
flag_scn_fullscreen='1'