Closed mikkorantalainen closed 2 years ago
Okay, I got it and took a look. :+1:
WINEPREFIX=$HOME/.fusion360 timeout -k 2m 1m winecfg
and then I checked the value with:
echo $?
Then I got the exit code 124. This value is the timeout used to indicate the program has terminated using SIGTERM. When SIGKILL terminates the program, the exit code is 137.
The script launches
wine
processes and then proceeds to kill them using a regex later. For example:https://github.com/cryinkfly/Autodesk-Fusion-360-for-Linux/blob/d655d4b88ed0acb8a1bffa95ac07b55af29fc9f3/files/builds/stable-branch/bin/install.sh#L379
Instead of doing hacks like this, how about using command
timeout
instead?If you executed the original wine command as
would send SIGTERM to the
wine
process after 9 minutes and SIGKILL after 10 minutes if the process is still running. Seeman timeout
for details.