Xfce Forum

Sub domains
 

You are not logged in.

#1 2016-04-08 05:25:19

Speranskiy
Member
Registered: 2016-02-02
Posts: 12

[Solved] Multiple commands inside genmon plugin script

Hi there!
I wonder if there is a way to execute two commands inside on <click> tag without evoking an additional script? I just want something like this

echo "<img>PATH/TO/IMAGE</img><click>some_command && another_command</click>

it appears that in this case only first command is executing.

Last edited by Speranskiy (2016-04-08 19:29:15)

Offline

#2 2016-04-08 10:22:27

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,950

Re: [Solved] Multiple commands inside genmon plugin script

It doesn't handle &s well. You need to embed them in a bash shell call. Try:

echo "<img>PATH/TO/IMAGE</img><click>bash -c 'some_command && another_command'</click>"

Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#3 2016-04-08 19:28:35

Speranskiy
Member
Registered: 2016-02-02
Posts: 12

Re: [Solved] Multiple commands inside genmon plugin script

Hi ToZ!
Haha! Actually I did tried to exec the commands inside sh -c but I used double quotes and it didn't work out for me smile Single quotes work much better! Thank you!

Last edited by Speranskiy (2016-04-08 19:29:48)

Offline

Board footer

Powered by FluxBB