From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: kgold@watson.ibm.com (kgold) Newsgroups: gmane.emacs.help Subject: Re: automatic selection of emacsclient/emacs? Date: 13 Jun 2005 18:27:52 GMT Organization: IBM T.J. Watson Research Center Message-ID: <42add028_1@news1.prserv.net> References: <2cydneqEPbdzxTvfRVn-uw@speakeasy.net> NNTP-Posting-Host: main.gmane.org X-Trace: sea.gmane.org 1118686306 5964 80.91.229.2 (13 Jun 2005 18:11:46 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 13 Jun 2005 18:11:46 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jun 13 20:11:46 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1DhtP8-0002KI-Nz for geh-help-gnu-emacs@m.gmane.org; Mon, 13 Jun 2005 20:11:23 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DhtTy-0001Ba-TR for geh-help-gnu-emacs@m.gmane.org; Mon, 13 Jun 2005 14:16:22 -0400 X-Newsreader: xrn 9.02 Original-Newsgroups: gnu.emacs.help Original-NNTP-Posting-Host: yktgi01e0-s5.watson.ibm.com Original-X-Trace: 13 Jun 2005 18:27:52 GMT, yktgi01e0-s5.watson.ibm.com Original-Lines: 33 Original-X-Complaints-To: abuse@prserv.net Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newscon02.news.prodigy.com!newscon06.news.prodigy.com!prodigy.net!newsfeed.us.prserv.net!prserv.net!news1.prserv.net!alpha.watson.ibm.com!kgold Original-Xref: shelby.stanford.edu gnu.emacs.help:131983 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:27453 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:27453 Dan Elliott writes: > Hattuari wrote: > > Is there a clean way to get Emacs to start as a client when there is an > > available server? I find it moderately annoying to have to look around to > > see if there is already an instance of Emacs started in order to determine > > if I should enter `emacs' or `emacsclient'. I much prefer running > > emacsclient when I already have one instance of Emacs running. One option > > is to try and sniff for emacs with ps and filter out the current processes > > such as grep emacs, and (assuming the script I'm running is also called > > emacs) the launch script. It would seem more correct to directly check to > > see if the service is available. Is there such a capability? > > Will I get flammed if I ask what the benefit of running emacs as a > client (opposed to the "usual" way) would be? Could this be an > alternative to using TRAMP? To Dan: As your .emacs gets bigger, the emacs startup time can become several seconds. With client/server, you just start emacs as a server once per login, and the new emacs clients attach very quickly. To Hattuari: I use gnuserv/gnuclient, but this might help. I use the command 'emacs' once to start the server at login. From then on, I alias 'e' to gnuclient to start clients. Since I always start the emacs server at login to read mail, my 'e' command never has to check if the server is running. -- Ken Goldman kgold@watson.ibm.com 914-784-7646