3

macOS has its "osascript" with "display notification", Linux has its "notify-send". Both are the most native way to generate DE notifications. What is the most native way to generate desktop notification in BSD unixes?

2
  • 2
    I think it would depend on what "desktop system" you're using, wouldn't it? BSD is the base OS and most don't really include a desktop beyond the basic X11 distribution and applications, with a basic window manager. The most basic X11 app for notifications would be xmessage. Jun 24 at 2:38
  • Isn't notify-send just a freedesktop idea? Should it then not apply to a the major desktop environments (say, GNOME, KDE), no matter whether you're running them on Linux or *BSD? It really isn't very "Linux-native": it just is a client making no use of specificities of the Linux kernel. Jun 24 at 7:15

1 Answer 1

0

As stated in OP's comment, most dekstop environments, in particular KDE-Plasma and Gnome use their own implementations to display notifications based on kernel agnostic DBus. Implementation that just cannot be replaced. ( Some notification daemon is started at DE launch time )


If all you want is to generate DE notifications, the standard way to proceed is to conform to the kernel agnostic Desktop Notifications Specification which the libnotify library implements.

If you also need a daemon because your DE does'nt implement anything then you should probably go with the notification-daemon.

3
  • I am looking for a command line utility like notify-send which is considered the most standard across DE on BSD's. It seems from Marcus Muller's comment that notify-send is the most native command line way to generate notifications? Do you think thats not the case?
    – reportaman
    Jun 24 at 7:23
  • @reportaman : It depends on what you mean by "native". From my understanding of the word, notify-send can't be said so since it is no more than a tool based on (and distributed by) libnotify. The most "native" and now standard way to send notifications is using DBus and conform to the Desjtop Notifications Specifications, libnotify being the most "native" API for their implementation. My understanding of your question was that, since you knew notify-send, you had the intention to write something else from scratch.
    – MC68020
    Jun 24 at 7:36
  • No, my intention is to write a function in shell script function that generates DE notifications for as many operating systems as possible. Thanks for your explanation and answer though.
    – reportaman
    Jun 24 at 7:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.