From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.devel Subject: emacsclient doesn't find server with non-standard name Date: Fri, 28 Dec 2012 19:45:28 +0100 Message-ID: <87han6aud3.fsf@web.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1356720271 16089 80.91.229.3 (28 Dec 2012 18:44:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 28 Dec 2012 18:44:31 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Dec 28 19:44:48 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ToevH-0000FQ-QG for ged-emacs-devel@m.gmane.org; Fri, 28 Dec 2012 19:44:47 +0100 Original-Received: from localhost ([::1]:53914 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Toev2-0006UO-So for ged-emacs-devel@m.gmane.org; Fri, 28 Dec 2012 13:44:32 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:52433) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Toeuz-0006Ty-J8 for emacs-devel@gnu.org; Fri, 28 Dec 2012 13:44:31 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Toeuw-0006s9-Am for emacs-devel@gnu.org; Fri, 28 Dec 2012 13:44:29 -0500 Original-Received: from mout.web.de ([212.227.17.11]:55148) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Toeuw-0006r2-0I for emacs-devel@gnu.org; Fri, 28 Dec 2012 13:44:26 -0500 Original-Received: from drachen.dragon ([82.113.98.201]) by smtp.web.de (mrweb102) with ESMTPA (Nemesis) id 0M5fwS-1Sr45X2ePw-00xTxA; Fri, 28 Dec 2012 19:44:24 +0100 Mail-Followup-To: emacs-devel@gnu.org User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.91 (gnu/linux) X-Provags-ID: V02:K0:BaHelrbz4GW7WgRCA8ovBMbtSYoOKFkJ6y7E860Efj7 xhG1gY2yoPd4VivpuyxA/Z8zGmmDYNg0YtlTCE/9P2YW6KeyIP Cwib25ekE8dNWnqgZumTQ4cARdNS/4tLVOSHujk+zzzMR2usmg fDN2ITmbbMlsKCqvoLb008qFVUymSDyzhKh4+tscoct5gdUxO1 vc7Se5Dk5uFw0hjKo2P2/hANIHfviqcB0O5odX3v98= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 212.227.17.11 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:155962 Archived-At: Hi, today I tried this: (progn (require 'server) (let ((server-name (concat "server_" (format-time-string "%H:%M:%S")))) (server-start))) This is on Debian with an Emacs compiled from the emacs-24 branch. If I then invoke emacsclient, it complains that it didn't find any server: | bash-4.2:micha:~$ emacsclient ~/.bashrc | emacsclient: can't find socket; have you started the server? | To start the server in Emacs, type "M-x server-start". | emacsclient: No socket or alternate editor. Please use: | | --socket-name | --server-file (or environment variable EMACS_SERVER_FILE) | --alternate-editor (or environment variable ALTERNATE_EDITOR) | bash-4.2:micha:~$ When I explicitly specify the server name with the -s option, emacsclient succeeds. However, I wonder why it is necessary to specify a name, because the man page of emacsclient says: | `-s SERVER-NAME' | `--socket-name=SERVER-NAME' | Connect to the Emacs server named SERVER-NAME. The server name is | given by the variable `server-name' on the Emacs server. If this | option is omitted, `emacsclient' connects to the first server it | finds. (This option is not supported on MS-Windows.) So, why doesn't emacsclient "find" any server? The socket is existent in /tmp/emacs$UID/. Why doesn't emacsclient just look there and use any of the sockets, as the doc seems to describe? Thanks, Michael.