From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: pjb@informatimago.com (Pascal J. Bourguignon) Newsgroups: gmane.emacs.help Subject: Re: EmacsClient: using both --eval and --alternate-editor, possible? Date: Sat, 13 Nov 2010 14:36:02 +0100 Organization: Informatimago Message-ID: <87d3q9uz0d.fsf@kuiper.lan.informatimago.com> References: <56b87357-849d-4189-9c3e-abf96ae4064e@t7g2000vbj.googlegroups.com> <877hgiwdsc.fsf@kuiper.lan.informatimago.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1291887101 13562 80.91.229.12 (9 Dec 2010 09:31:41 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 9 Dec 2010 09:31:41 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Dec 09 10:31:37 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PQcqc-0005hc-El for geh-help-gnu-emacs@m.gmane.org; Thu, 09 Dec 2010 10:31:34 +0100 Original-Received: from localhost ([127.0.0.1]:56412 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PQcqb-0000C6-FD for geh-help-gnu-emacs@m.gmane.org; Thu, 09 Dec 2010 04:31:33 -0500 Original-Path: usenet.stanford.edu!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 36 Original-X-Trace: individual.net DDTXkgj6+xWZOcCn8o7sfA/sfeR3eliDuVh+wwrE+36dp1IL92 Cancel-Lock: sha1:YTUyNmI5ZDEzYmUzOTMzYmU0ZTBkZmRiOTY3NWMzOTBmOGQ0MmMwZQ== sha1:fKP0FG89CkvZjfcze3h5tlfErIs= Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAQMAAABtzGvEAAAABlBMVEUAAAD///+l2Z/dAAAA oElEQVR4nK3OsRHCMAwF0O8YQufUNIQRGIAja9CxSA55AxZgFO4coMgYrEDDQZWPIlNAjwq9 033pbOBPtbXuB6PKNBn5gZkhGa86Z4x2wE67O+06WxGD/HCOGR0deY3f9Ijwwt7rNGNf6Oac l/GuZTF1wFGKiYYHKSFAkjIo1b6sCYS1sVmFhhhahKQssRjRT90ITWUk6vvK3RsPGs+M1RuR mV+hO/VvFAAAAABJRU5ErkJggg== X-Accept-Language: fr, es, en X-Disabled: X-No-Archive: no User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) Original-Xref: usenet.stanford.edu gnu.emacs.help:182397 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:76922 Archived-At: Richard Riley writes: > pjb@informatimago.com (Pascal J. Bourguignon) writes: > >> Elena writes: >> >>> Hello, >>> >>> I think there is a conflict between --eval and --alternate-editor >>> option in EmacsClient. If Emacs is not running and thus --eval fails, >>> the EDITOR indicated with --alternate-editor is called instead. >>> However, such EDITOR gets an ELisp expression, which it can't handle. >>> Is there a way around this, other than wrapping EmacsClient into a >>> script? >> >> Obviously, you need to patch this other editor to make it understand >> elisp. This is indeed an awful but that need immediate action. Either >> you integrate elisp in that alternate editor, or you rm it. > > Or alternatively, and much more useful and helpful, if emacs uses the > alternative editor then it doesnt pass the eval statement to that other > editor since it knows the elisp eval statement is useless.. This is silly. Obviously, the alternate editor is also an emacs. For example: /opt/local/bin/emacsclient --alternate-editor=/usr/bin/emacs -e '(emacs-version)' if for some reason the X11 emacs provided by MacPorts is not available, I fallback to the bare terminal emacs provided by Apple. -- __Pascal Bourguignon__ http://www.informatimago.com/ A bad day in () is better than a good day in {}.