1

When I launch gedit or firefox from a terminal, the terminal is occupied(by occupied I mean no other commands can be run from the same terminal window) untill I press ctrl+c but it kills gedit or firefox. Any way other than opening a new terminal window?

marked as duplicate by Radu Rădeanu, ImaginaryRobots, Eric Carvalho, kiri, karel Dec 31 '13 at 2:31

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

0

You put the applications into the background with the & ...

firefox &

If you want to re-direct error messages and close the terminal leaving the applications running,

nohup firefox > /dev/null 2>&1 &
1

As per http://www.linuxandlife.com/2012/07/how-to-run-multiple-commands-in-terminal.html follow the command to launch the app with an ampersand, e.g.:

firefox &

gedit &

Following the command with the ampersand launches the app then returns cursor control to the terminal window immediately so you are free to run another command within that window.

  • That will not work, the commands will hang until you exit firefox – Panther Dec 30 '13 at 22:43
  • I don't want to run multiple commands...it is that when i use the command gedit the terminal is occupied and can't take any other command until is press ctrl+c and when i press ctrl+c the program gedit gets killed as well. So i wanted to know is there any other ways of doing that without opening another terminal window...?? – Muddassir Nazir Dec 30 '13 at 22:43
  • No, not && , just a single &. If you use && or || , that is something else. See stackoverflow.com/questions/4510640/… – Panther Dec 30 '13 at 22:46

Not the answer you're looking for? Browse other questions tagged or ask your own question.