From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel Subject: RE: testing for a remote file to include file on a Windows mappeddrive Date: Sat, 26 Jan 2008 08:55:51 -0800 Message-ID: References: <871w844yff.fsf@gmx.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1201366651 23931 80.91.229.12 (26 Jan 2008 16:57:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 26 Jan 2008 16:57:31 +0000 (UTC) Cc: Jason Rumney , Emacs-Devel To: "Michael Albinus" , "Stefan Monnier" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jan 26 17:57:51 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JIoLj-000158-6i for ged-emacs-devel@m.gmane.org; Sat, 26 Jan 2008 17:57:47 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JIoLI-0008Nq-QM for ged-emacs-devel@m.gmane.org; Sat, 26 Jan 2008 11:57:20 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JIoLD-0008N1-Jd for emacs-devel@gnu.org; Sat, 26 Jan 2008 11:57:15 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JIoLB-0008M0-TB for emacs-devel@gnu.org; Sat, 26 Jan 2008 11:57:15 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JIoLB-0008Lw-M0 for emacs-devel@gnu.org; Sat, 26 Jan 2008 11:57:13 -0500 Original-Received: from agminet01.oracle.com ([141.146.126.228]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JIoL4-0006Ay-DD; Sat, 26 Jan 2008 11:57:06 -0500 Original-Received: from rgmgw2.us.oracle.com (rgmgw2.us.oracle.com [138.1.186.111]) by agminet01.oracle.com (Switch-3.2.4/Switch-3.1.7) with ESMTP id m0QGv1mN016199; Sat, 26 Jan 2008 10:57:01 -0600 Original-Received: from acsmt351.oracle.com (acsmt351.oracle.com [141.146.40.151]) by rgmgw2.us.oracle.com (Switch-3.2.4/Switch-3.2.4) with ESMTP id m0QDcsCu030573; Sat, 26 Jan 2008 09:57:00 -0700 Original-Received: from inet-141-146-46-1.oracle.com by acsmt351.oracle.com with ESMTP id 3539359691201366550; Sat, 26 Jan 2008 08:55:50 -0800 Original-Received: from dradamslap1 (/141.144.72.89) by bhmail.oracle.com (Oracle Beehive Gateway v4.0) with ESMTP ; Sat, 26 Jan 2008 08:55:49 -0800 X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) In-Reply-To: <871w844yff.fsf@gmx.de> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198 X-Brightmail-Tracker: AAAAAQAAAAI= X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-Whitelist: TRUE X-detected-kernel: by monty-python.gnu.org: Linux 2.4-2.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:87584 Archived-At: > file-remote-p returns information about the *file name*, and not > necessarily about the file: "Can the file name be used literally on the > local host?" I believe this meaning shall be kept, for example, it is > needed to determine whether a file name must be trimmed when used as > argument of process-file and alike. > > The new function you are looking for is file-mounted-p or so. In my case, and I think in many (most?) cases where `file-remote-p' is used today, it is, as you say, not necessary to know much about an actual file; it is enough to know that a given file name is *likely* to represent a remote file. Note that it is possible that a local file have a name that matches any of the various "remote-file" syntaxes. The syntax is not proof that a file is remote. In my case, I am not really looking for `file-mounted-p'. Again, I don't really care if such and such a file is really local or remote or on a mounted (mapped) drive or directory. I only want to know if it is *likely* that it is. That means that I don't need a (possibly more costly) function to check things out remotely to determine whether such a remote/mounted file exists.