I like to start GUI programs from the terminal, e.g.
emacs myfile.txt. But doing that leaves a terminal window open with that process, so now there are two windows for me to keep track of. And if I close the terminal window, the GUI program closes.
I know I can run
exec cmd, where
cmd is the command I'm trying to run, and that closes the terminal window after the program completes. But I want to close the terminal window after the command is launched. Is there a way to do that?