How do I start applications without having a terminal window remain open?
Newbie to Linux here; How do I start programs like Firefox without a terminal window having to remain open?
At the moment I start them by typing the relevant command in a terminal window, and if I close that terminal window the program closes; at the same time I can't type anything in that terminal, which is understandable.
Any help is appreciated.
About this post
- Posted
- Archived
- Score
- 1 · 100% up
- Kind
- Text
- ID
- ijerd9
9 comments
I mean you can add a & to the end of the command so it stays in the background and you can keep using the terminal but you shouldn't be launching stuff like firefox from a terminal anyway(at least outside of debugging purposes), you should be using a launcher like dmenu for instance.
Ah, yes, a launcher, that sounds like something I should have, thank you.
Maybe this is a dumb question, but why shouldn’t Firefox be launched with the terminal?
It's not like it's downright wrong or anything, but i just think there's better ways to launch it instead of opening a terminal to launch firefox or any other GUI app, you can just use dmenu or rofi or even assign a keybind to launch it and if you are using a regular desktop environment then you will have some shortcut to it on the desktop or task bar.
It's still useful to launch it sometimes through a terminal if it's crashing or not launching so you can get more information.
You can also add "& disown" after command and safely close the terminal.
Besides launchers (as mentioned by others) and keybindings in your window manager, you could look up "nohup" and "disown".
Add a & to escape your command.
e.g.
$> /usr/bin/Firefox &
click on terminal then press control + z then type bg and you can now close terminal