Zren / plasma-applet-commandoutput

https://store.kde.org/p/1166510/
GNU General Public License v2.0
87 stars 18 forks source link

Forcing the command to run also after running a script on click #39

Open Sadi58 opened 1 year ago

Sadi58 commented 1 year ago

In some use cases it can be necessary to force the command (e.g. checking and displaying the status of something every 60 minutes) to run immediately after clicking the widget (and running a script that can change the status in question). I wonder if this can be achieved with or without some modification in this widget.

elabjer commented 6 months ago

hey. I needed this as well, so I modified the applet.. just insert this in main.qml immediately after line 230: if (cmd == config.clickCommand) { executable.exec(config.command) }

Sadi58 commented 6 months ago

After exactly one year, I forgot what I had in mind when I needed it. 😄 This brings up another idea: to list some examples of Command Output widget in action somewhere here...

Sadi58 commented 6 months ago

As such a fixed feature would be undesirable in some use cases, it seems the best solution could be to include it as an option in the settings so that it can be enabled or disabled in each use of the widget.