Using notify-send with multiple lines in body
Hey all,
I'm trying to setup a hotkey in KDE that will popup a notification with the current playlist I have running in an xmms2 server. I currently have some hotkeys such as the following actions, which work fine: Code:
xmms2 prev; notify-send "Currently Playing" "`xmms2 current`" Code:
notify-send "Current Playlist" "`xmms2 list`" I've tried using sed to do this, but I don't know enough about it. From what I can tell, the following has no effect on the output (nor do any variations I have tried thus far): Code:
xmms2 list | sed '{s/\n/<br>/g}' Anyone have any recommendations? |
I think xmms2 has configuration options to modify the output of the list command, maybe it has an html/xml option
|
I've never seen any problem when dealing with notify-send in this regard.
Can you test something simple like this and see if it works? Code:
$ notify-send foo "bar |
Quote:
|
It depends on which program provides the notifications!
Which notification daemon does your system use? Code:
dpkg -l | grep -i notfication FWIW, I use dunst and something like Code:
notify-send Title "$(mpc)" Code:
notify-send Title "bla\nbla\nbla" |
Summary required
OMG, I had tried using \n already but with no luck. Since you posted using the same I tried again and it failed... then I tried with Title and it worked. That is called {summary} in the man page and otherwise doesn't seem to be required but it did make \n work.
notify-send "bla\nbla" puts bla\nbla on the screen notify-send Title "bla\nbla" puts on the screen: Title bla bla OS = Linux Mint 20.2 Thank you Ondoho |
All times are GMT -5. The time now is 08:41 PM. |