https://github.com/kgilmer/vala-dbus-notification-backend-sample
A concise example of a dbus org.freedesktop.Notification backend in Vala
https://github.com/kgilmer/vala-dbus-notification-backend-sample
dbus-service gnome vala vala-developers
Last synced: 3 months ago
JSON representation
A concise example of a dbus org.freedesktop.Notification backend in Vala
- Host: GitHub
- URL: https://github.com/kgilmer/vala-dbus-notification-backend-sample
- Owner: kgilmer
- License: mit
- Created: 2019-12-04T16:03:46.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-12-04T16:17:02.000Z (over 6 years ago)
- Last Synced: 2025-01-30T07:29:58.700Z (over 1 year ago)
- Topics: dbus-service, gnome, vala, vala-developers
- Language: Vala
- Homepage:
- Size: 2.93 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# notification-backend
This is a sample a dbus-based [freedesktop notification backend](https://developer.gnome.org/notification-spec/) written in Vala.
# Why?
There are some existing samples on the internet but they are old and I could not get them to work. I ended up copying a [Python variant](https://github.com/DaveDavenport/Rofication) and was able to get the sample to print simple messages when notifications are generated.
# How
Build and run the backend:
```
$ make
$ G_MESSAGES_DEBUG=all ./notification-backend
```
In another terminal, send a notification:
```
$ notify-send boo
```
Notice the backend print a message reporting it received a notification:
```
** (process:5737): DEBUG: 08:08:38.810: notification-backend.vala:9: Got notification
```