Can you close a program from the terminal with TERM?

Questions about applications and software
Forum rules
Before you post please read this

Can you close a program from the terminal with TERM?

Postby BostonPeng on Mon Nov 05, 2012 10:14 am

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?
J.M. "BostonPeng" Hardin
Now very happily running SolydK
My new Linux blog: Tux + Me
It's time for Dodgers baseball!
User avatar
BostonPeng
Level 5
Level 5
 
Posts: 619
Joined: Mon Aug 02, 2010 8:50 am
Location: Boston, MA

Linux Mint is funded by ads and donations.
 

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

Postby Beardedragon on Mon Nov 05, 2012 12:04 pm

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.
Robert Collard, Madison, WI
HP s5710f, 2x AMD Athlon II 260@3.2Ghz, 3GB RAM, 640GB HD
Debian 7.1 Wheezy 3,2,0-4 Xfce 4.10 AMD-64
LMDE 3.10.5-1 Xfce 4.10 AMD-64
SalineOS 2.0 3.2.0-4 Xfce 4.8 AMD64
User avatar
Beardedragon
Level 4
Level 4
 
Posts: 346
Joined: Sat Jan 29, 2011 3:37 am

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

Postby BostonPeng on Mon Nov 05, 2012 12:31 pm

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.
J.M. "BostonPeng" Hardin
Now very happily running SolydK
My new Linux blog: Tux + Me
It's time for Dodgers baseball!
User avatar
BostonPeng
Level 5
Level 5
 
Posts: 619
Joined: Mon Aug 02, 2010 8:50 am
Location: Boston, MA

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

Postby cwsnyder on Mon Nov 05, 2012 6:23 pm

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?
LMDE Mate 64-bit, LM16 Mate 64-bit
Debian Xfce 64-bit, Xubuntu 13.10 64-bit, Xubuntu Trusty Tahr 64-bit, Antergos Xfce 64-bit, PCLinuxOS LXDE 64-bit
cwsnyder
Level 6
Level 6
 
Posts: 1039
Joined: Wed Oct 20, 2010 6:49 am
Location: Nappanee, IN, USA

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

Postby BostonPeng on Tue Nov 06, 2012 2:46 pm

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.
J.M. "BostonPeng" Hardin
Now very happily running SolydK
My new Linux blog: Tux + Me
It's time for Dodgers baseball!
User avatar
BostonPeng
Level 5
Level 5
 
Posts: 619
Joined: Mon Aug 02, 2010 8:50 am
Location: Boston, MA


Return to Software & Applications

Who is online

Users browsing this forum: Bing [Bot] and 22 guests