LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 10-01-2005, 11:01 AM   #1
kornerr
Member
 
Registered: Dec 2004
Location: Russia, Siberia, Kemerovo
Distribution: Slackware
Posts: 893

Rep: Reputation: 35
How to launch an app in terminal, & keep it running after I close terminal?


I like terminal, but sometimes I need to use Nautilus to launch, e.g., PDF viewer.
Then I usually close Nautilus and go on watching PDF.
I want to do the same from within terminal.

Is there a way to launch an app from terminal, and keep it running after I close the terminal?
(I'm not asking of "&" suffix)

Thanks.
 
Old 10-01-2005, 12:04 PM   #2
jailbait
Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Wheezy, Debian Jessie
Posts: 7,590

Rep: Reputation: 188Reputation: 188
"Is there a way to launch an app from terminal, and keep it running after I close the terminal?
(I'm not asking of "&" suffix)"

You could minimize the terminal.

----------------------
Steve Stites
 
Old 10-01-2005, 12:28 PM   #3
aysiu
Senior Member
 
Registered: May 2005
Distribution: Ubuntu with IceWM
Posts: 1,776

Rep: Reputation: 66
Don't launch it from terminal. Use the "Run" command instead.
 
Old 10-01-2005, 12:46 PM   #4
perfect_circle
Senior Member
 
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783

Rep: Reputation: 52
Re: How to launch an app in terminal, & keep it running after I close terminal?

Quote:
Originally posted by kornerr
I like terminal, but sometimes I need to use Nautilus to launch, e.g., PDF viewer.
Then I usually close Nautilus and go on watching PDF.
I want to do the same from within terminal.

Is there a way to launch an app from terminal, and keep it running after I close the terminal?
(I'm not asking of "&" suffix)

Thanks.
hi kornerr, you are looking for the "nohup" command. Next time you launch such a command from a terminal, launch it like this:
Code:
nohup <command>
 
Old 10-01-2005, 04:39 PM   #5
Komakino
Senior Member
 
Registered: Feb 2004
Location: Somerset, England
Distribution: Slackware 10.2, Slackware 10.0, Ubuntu 9.10
Posts: 1,938

Rep: Reputation: 54
alternatively, once you have it running in the background, type:
Code:
exit
to close the terminal and leave the app running.
 
Old 10-01-2005, 07:09 PM   #6
perfect_circle
Senior Member
 
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783

Rep: Reputation: 52
Thats true, I had never noticed this. Typing "exit" or pressing CTRL+D in the terminal also does the job.
I think I learned something today....
 
Old 10-01-2005, 11:13 PM   #7
kornerr
Member
 
Registered: Dec 2004
Location: Russia, Siberia, Kemerovo
Distribution: Slackware
Posts: 893

Original Poster
Rep: Reputation: 35
Thanks, perfect_circle, Komakino.

Never knew that "exit" is so smart
 
Old 06-24-2006, 06:54 PM   #8
spiral out
LQ Newbie
 
Registered: Jun 2006
Posts: 2

Rep: Reputation: 0
and i found out that when you run in terminal window:
Code:
<program> &exit
the terminal will close automatically...

maybe old news...
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Check if an app is running and if it's not launch this app Coume Linux - General 3 07-28-2008 03:34 AM
Problem running console app in X with no terminal (as a desktop shortcut) kornerr Linux - General 1 02-04-2005 01:08 AM
can you close a cd drive from the terminal? dr_zayus69 Linux - Hardware 4 12-01-2004 09:30 PM
Alternative terminal to konsole & gnome-terminal Adony Linux - Software 3 10-08-2004 04:59 AM
lines remaining when I launch an app or terminal spiteres Linux - General 0 05-27-2003 07:24 AM


All times are GMT -5. The time now is 07:24 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration