All Projects → vlevit → Notify Send.sh

vlevit / Notify Send.sh

Licence: gpl-3.0
drop-in replacement for notify-send with more features

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to Notify Send.sh

Bitprophet
Node crypto trading platform for Binance exchange.
Stars: ✭ 166 (-17%)
Mutual labels:  notifications
React Notify Toast
Toast notifications for React.js
Stars: ✭ 176 (-12%)
Mutual labels:  notifications
Sweetalert2
A beautiful, responsive, highly customizable and accessible (WAI-ARIA) replacement for JavaScript's popup boxes. Zero dependencies.
Stars: ✭ 13,929 (+6864.5%)
Mutual labels:  notifications
Timeago
This will help to get how much time have passed. Useful in showing messages, notifications time and etc.
Stars: ✭ 169 (-15.5%)
Mutual labels:  notifications
Bdialog
Extend the Bootstrap Modal features, making dialog more functions and easier to use, dialog type including modal, alert, mask and toast types
Stars: ✭ 174 (-13%)
Mutual labels:  notifications
Shoutrrr
Notification library for gophers and their furry friends.
Stars: ✭ 177 (-11.5%)
Mutual labels:  notifications
Screamer Js
Screamer.js is a Vanilla Javascript plugin to provide simple yet fully customisable web notifications using Web Notifications API.
Stars: ✭ 161 (-19.5%)
Mutual labels:  notifications
Apns Http2
A Java library for sending notifications via APNS using Apple's HTTP/2 API.
Stars: ✭ 194 (-3%)
Mutual labels:  notifications
Angular Notifier
A well designed, fully animated, highly customizable, and easy-to-use notification library for your Angular application.
Stars: ✭ 175 (-12.5%)
Mutual labels:  notifications
Python Notifyall
A library which can be used for all types of notifications like SMS, Mail, Push.
Stars: ✭ 185 (-7.5%)
Mutual labels:  notifications
Notiflix
Notiflix is a JavaScript library for client-side non-blocking notifications, popup boxes, loading indicators, and more that makes your web projects much better.
Stars: ✭ 172 (-14%)
Mutual labels:  notifications
Amplify Cli
The AWS Amplify CLI is a toolchain for simplifying serverless web and mobile development.
Stars: ✭ 2,399 (+1099.5%)
Mutual labels:  notifications
Cmus Osx
Adds track change notifications, and media key support to cmus.
Stars: ✭ 179 (-10.5%)
Mutual labels:  notifications
Ember Cli Notifications
⚛ Atom inspired notification messages for ember-cli
Stars: ✭ 168 (-16%)
Mutual labels:  notifications
Ng2 Notifications
Angular 2 Component for Native Push Notifications [Looking for New Maintainers]
Stars: ✭ 192 (-4%)
Mutual labels:  notifications
Autoya
thin framework for Unity.
Stars: ✭ 165 (-17.5%)
Mutual labels:  notifications
Googlecontactseventsnotifier
Receive automatic email notifications before your Google Contacts birthday and other events!
Stars: ✭ 177 (-11.5%)
Mutual labels:  notifications
Budgie Desktop
I Tawt I Taw A Purdy Desktop
Stars: ✭ 2,374 (+1087%)
Mutual labels:  notifications
Hawkeye
A useful app for GitHub Notifications
Stars: ✭ 193 (-3.5%)
Mutual labels:  notifications
Dllocalnotifications
💬 Easily create Local Notifications in swift - Wrapper of UserNotifications Framework
Stars: ✭ 182 (-9%)
Mutual labels:  notifications

notify-send.sh

notify-send.sh is a drop-in replacement for notify-send (from libnotify) with ability to update and close existing notifications.

The dependencies are bash and gdbus (shipped with glib2).

In Debian and Ubuntu you can ensure all dependencies are installed with the following command:

$ sudo apt-get install bash libglib2.0-bin

For Arch Linux users notify-send.sh is available in AUR.

Usage

notify-send.sh has all command line options of notify-send with a few additional ones:

Usage:
  notify-send.sh [OPTION...] <SUMMARY> [BODY] - create a notification

Help Options:
  -?|--help                         Show help options

Application Options:
  -u, --urgency=LEVEL               Specifies the urgency level (low, normal, critical).
  -t, --expire-time=TIME            Specifies the timeout in milliseconds at which to expire the notification.
  -a, --app-name=APP_NAME           Specifies the app name for the icon
  -i, --icon=ICON[,ICON...]         Specifies an icon filename or stock icon to display.
  -c, --category=TYPE[,TYPE...]     Specifies the notification category.
  -h, --hint=TYPE:NAME:VALUE        Specifies basic extra data to pass. Valid types are int, double, string and byte.
  -o, --action=LABEL:COMMAND        Specifies an action. Can be passed multiple times. LABEL is usually a button's label. COMMAND is a shell command executed when action is invoked.
  -d, --default-action=COMMAND      Specifies the default action which is usually invoked by clicking the notification.
  -l, --close-action=COMMAND        Specifies the action invoked when the notification is closed.
  -p, --print-id                    Print the notification ID to the standard output.
  -r, --replace=ID                  Replace existing notification.
  -R, --replace-file=FILE           Store and load notification replace ID to/from this file.
  -s, --close=ID                    Close notification.
  -v, --version                     Version of the package.

So, for example, to notify a user of a new email we can run:

$ notify-send.sh --icon=mail-unread --app-name=mail --hint=string:sound-name:message-new-email Subject Message

To replace or close existing message first we should know its id. To get id we have to run notify-send.sh with --print-id:

$ notify-send.sh --print-id Subject Message
10

Now we can update this notification using --replace option:

$ notify-send.sh --replace=10 --print-id "New Subject" "New Message"
10

Now we may want to close the notification:

$ notify-send.sh --close=10

Use --replace-file to make sure that no more than one notification is created per file. For example, to increase volume by 5% and show the current volume value you can run:

$ notify-send.sh --replace-file=/tmp/volumenotification "Increase Volume" "$(amixer sset Master 5%+ | awk '/[0-9]+%/ {print $2,$5}')"

You can add a button to the notification with -o or --default-action=:

$ notify-send.sh "Subject" "Message" -o "Show another notification:notify-send.sh 'new Subject' 'New Message'"

You can specify multiple actions by passing -o multiple times. Use -d or --default-action for action which is usually invoked when notification area is clicked. Use -l or --close-action for action performed when notification is closed.

$ notify-send.sh "Subject" "Message" \
    -d "notify-send.sh 'Default Action'" \
    -o "Button Action:notify-send.sh 'Button Action'" \
    -l "notify-send.sh 'Close Action'"
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].