Can you close a program from the terminal with TERM?

Questions about applications and software
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
BostonPeng

Can you close a program from the terminal with TERM?

Post by BostonPeng »

I've got the Smile Desktop (a Windows app) running under CrossOver Linux but I'm unable to close the program from the icon in the system tray. I can close it from the System Manager/Top by sending the TERM signal and that's the way that seems to work best for me. I know I can close it from the terminal with killall but that seems to cause problems with not saving settings, etc., for the next time I launch it. Is there a way to send a TERM signal from the terminal?
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Beardedragon

Re: Can you close a program from the terminal with TERM?

Post by Beardedragon »

Not sure of the exact command. Open Terminal and copy/paste:

Code: Select all

sudo man kill
it will give you the variants for the correct command.
BostonPeng

Re: Can you close a program from the terminal with TERM?

Post by BostonPeng »

Beardedragon wrote:Not sure of the exact command. Open Terminal and copy/paste:

Code: Select all

sudo man kill
it will give you the variants for the correct command.
Thanks. I see I can specify signal 15 SIGTERM but I'm getting a complaint about needing a process or job ID, and I'd prefer to use the program name (Smile.exe) so I can turn it into a launcher or a bash script.
cwsnyder

Re: Can you close a program from the terminal with TERM?

Post by cwsnyder »

You can look for the Process ID in the top and similar programs, but kill and similar programs all search by process ID, not by name. Windows has the same problem, you must identify the program yourself, not simply type in a program name to finish the program.

Have you tried simply selecting the window and using the Alt-F4 key combination to close the window?
BostonPeng

Re: Can you close a program from the terminal with TERM?

Post by BostonPeng »

I can close the Smile Desktop without a problem, but it includes a system tray icon that stays until you completely close the program, and it doesn't recognize right-clicks under Wine. That's what I was hoping to close from the terminal but I'll just use the handy System Monitor icon I put in Fancy tasks for closing it.
Locked

Return to “Software & Applications”