Implicitly launch detached program (&) from terminal

I feel sure this will end up as a duplicate, but I don't know how to word it so that I can search for it...

I like to do my programming in emacs, which I launch from the terminal. When I use my mac I use aquamacs and the command


will launch aquamacs in a separate window ready to edit When I work on my linux machine however to get the same result I must type

emacs &

And I'm always forgetting the "&". So 70% of the time I end up closing the emacs window, and relaunching again with the "&". Now I understand why that "&" is there, but is there a way to set up my system so that the command


always launches as a detached process? The only time I might not want that behavior is if I was SSHing in over a slow connection, in which case I usually use "-nw" anyway.


You can click on the terminal and press Ctrl-Z to move an already running foreground process to the background.

Alternatively you could add this function to your ~/.bashrc:

emacs() {
    command emacs "$@" &

Need Your Help

Viewing SSRS Reports in an MVC Site

c# reportviewer reporting-services

Is there a way to put a SQL Server Reporting Services report viewer control on an MVC view? If not...what is the best way to accomplish this?

Object initialization failed in static block

java oop java-ee constructor static-block

I want to create an array of class objects and initialize it also without using any method so i wrote code like this: