Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
How Can I Run a Script That Won't Terminate With Qt App?
closx last edited by closx
I am basically trying to run a script that will change my running application with another version.
In OS, my app runs as a service called "myapp". My basic script,
#!/bin/sh sudo service myapp stop #killing my application sleep(3) #waiting for the finish rm my_app #removing old executable cp update/my_app . #copying new app to the main dir sudo service myapp start #starting it again
In Qt, I am calling the script to run, like that,
But as it reaches the 3rd line of the script (
sudo service myapp stop),
the script terminates with the application, and nothing is being updated.
How can I run it so it won't terminate?
Maybe running in a new shell? But how?
closx last edited by
@jsulm Thank for your answer! That worked.
Pablo J. Rogina last edited by
Great. Please mark your post as solved! Thanks.