Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I recently started using emacsclient, and I like it a lot. Until now I haven't had any problems, but I just made a new tab in my terminal and tried opening another file, but emacs gets stuck on "Waiting for Emacs...". How do I run two emacsclients so I can edit two files? I'm on Ubuntu 13.04 with emacsclient 23.4 and emacs 23.4.1.

In order to start emacsclient and emacs server, I have the following bash function:

function emacs {
    if [[ $# -eq 0 ]]; then
        emacsclient -c -nw -a ""
    else
        emacsclient "$@" -a ""
    fi
}

So for example I could start a terminal and emacs server would not be running. Then I would type emacs file.txt which would start an emacs server and connect with an emacs client. Then I would make a new tab and type emacs file2.txt and I wouldn't be able to connect.

share|improve this question
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.