unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* testing for a remote file to include file on a Windows mapped drive
@ 2008-01-25 18:47 Drew Adams
  2008-01-25 18:54 ` Drew Adams
                   ` (2 more replies)
  0 siblings, 3 replies; 135+ messages in thread
From: Drew Adams @ 2008-01-25 18:47 UTC (permalink / raw)
  To: Emacs-Devel

I have some code that needs to avoid some particular processing when the
current input might name a remote file. I don't want the code to try to
contact anything remote in this case.

In Windows, you can map a remote directory to a virtual drive. So, for
instance, "h:foo" or "h:/foo" might represent a remote file. But the same
name would represent a local file if drive `h' is local, not mapped.

How can I test in Emacs, for Windows, whether a drive is local or mapped, in
order to determine whether "h:foo" might be local or remote?

AFAICT, the various ways Emacs uses to test file-name syntax to determine
remoteness do not take Windows drive mapping into account. I don't know if
that's a problem for Emacs in general (why wouldn't it be?), but it is a
problem for my use case.

I've looked at these. None does what I need.

. file-remote-p
. ffap-file-remote-p
. dired-sort-menu-remote-p
  "\\`/\\([^@:/]+@\\)?\\([^:/]+\\):"
. ange-ftp-name-format
  "\\`/\\(\\([^/:]*\\)@\\)?\\([^@/:]*[^@/:.]\\):\\(.*\\)"
. remote (ange-ftp) filenames (see make-auto-save-file-name)
  "^/\\w+@[-A-Za-z0-9._]+:"
. ffap-ftp-regexp
  "\\`/[^/:]+:"

Suggestions?

^ permalink raw reply	[flat|nested] 135+ messages in thread

end of thread, other threads:[~2008-05-05 18:31 UTC | newest]

Thread overview: 135+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-25 18:47 testing for a remote file to include file on a Windows mapped drive Drew Adams
2008-01-25 18:54 ` Drew Adams
2008-01-25 20:33   ` testing for a remote file to include file on a Windows mappeddrive Drew Adams
2008-01-25 22:18     ` Jason Rumney
2008-01-25 23:37       ` Drew Adams
2008-01-26  2:56         ` Stefan Monnier
2008-01-26  7:30           ` Drew Adams
2008-01-26  9:54             ` Eli Zaretskii
2008-01-26 11:29           ` Michael Albinus
2008-01-26 15:23             ` Jason Rumney
2008-01-26 16:55             ` Drew Adams
2008-01-26 19:24             ` Stefan Monnier
2008-01-26 22:15               ` Michael Albinus
2008-01-26 22:31                 ` Eli Zaretskii
2008-01-27 11:18                   ` Michael Albinus
2008-01-27 17:28                     ` Eli Zaretskii
2008-01-27 18:22                       ` Andreas Schwab
2008-01-27 19:04                       ` Michael Albinus
2008-01-27  1:36                 ` Drew Adams
2008-01-27 20:46                   ` Stefan Monnier
2008-04-20 18:28                   ` testing for a remote file to include file on a Windows mapped drive Drew Adams
2008-04-20 19:37                     ` Stefan Monnier
2008-04-20 20:03                       ` Lennart Borgman (gmail)
2008-04-20 20:28                         ` Stefan Monnier
2008-04-20 21:13                         ` Eli Zaretskii
2008-04-20 21:16                           ` Lennart Borgman (gmail)
2008-04-20 21:31                         ` Jason Rumney
2008-04-20 20:24                       ` Drew Adams
2008-04-20 21:19                         ` Eli Zaretskii
2008-04-20 22:20                           ` Drew Adams
2008-04-20 21:21                         ` Stefan Monnier
2008-04-20 22:20                           ` Drew Adams
2008-04-21  0:59                             ` Stefan Monnier
2008-04-21  7:18                               ` Drew Adams
2008-04-21  7:28                                 ` Jason Rumney
2008-04-21  7:47                                   ` Drew Adams
2008-04-21 19:37                                     ` Eli Zaretskii
2008-04-21 22:11                                       ` Drew Adams
2008-04-22  3:36                                         ` Eli Zaretskii
2008-04-22  4:43                                           ` Drew Adams
2008-04-22  6:27                                             ` Eli Zaretskii
2008-04-22 14:09                                               ` testing for a remote file to include file on a Windowsmapped drive Drew Adams
2008-04-22 15:47                                                 ` Eli Zaretskii
2008-04-21 17:08                                   ` testing for a remote file to include file on a Windows mapped drive Drew Adams
2008-04-21  7:46                                 ` Michael Albinus
2008-04-21  7:55                                   ` Drew Adams
2008-04-21  9:03                                     ` Michael Albinus
2008-04-21  8:57                                   ` Andreas Schwab
2008-04-21  9:11                                     ` Michael Albinus
2008-04-21  9:18                                       ` Andreas Schwab
2008-04-21  9:44                                         ` Michael Albinus
2008-04-21  9:59                                           ` Andreas Schwab
2008-04-21 14:36                                       ` Stefan Monnier
2008-04-21 17:09                                         ` Drew Adams
2008-04-21 17:45                                           ` Stefan Monnier
2008-04-21 18:52                                             ` Drew Adams
2008-04-21 19:21                                               ` Stefan Monnier
2008-04-21 22:39                                                 ` Drew Adams
2008-04-21 14:33                                   ` Stefan Monnier
2008-04-21 15:13                                     ` Michael Albinus
2008-04-21 16:17                                       ` Stefan Monnier
2008-04-21 20:29                                         ` Michael Albinus
2008-04-22  2:48                                           ` Stefan Monnier
2008-04-21 19:35                                     ` Eli Zaretskii
2008-04-22  2:46                                       ` Stefan Monnier
2008-04-22  3:40                                         ` Eli Zaretskii
2008-04-22  5:46                                           ` Stefan Monnier
2008-04-22  6:50                                             ` Eli Zaretskii
2008-04-22 15:17                                         ` Michael Albinus
2008-04-29  7:50                                           ` Stefan Monnier
2008-04-29 18:15                                             ` Eli Zaretskii
2008-04-29 20:39                                               ` Stefan Monnier
2008-04-30  3:16                                                 ` Eli Zaretskii
2008-04-30  4:26                                                   ` Stefan Monnier
2008-04-30  6:23                                                     ` Drew Adams
2008-04-30  7:34                                                       ` Stefan Monnier
2008-04-30 13:57                                                         ` Drew Adams
2008-05-05 15:33                                                           ` Michael Albinus
2008-05-05 15:47                                                             ` Drew Adams
2008-05-05 15:57                                                               ` Michael Albinus
2008-05-05 16:12                                                                 ` Drew Adams
2008-05-05 18:31                                                             ` Stefan Monnier
2008-05-05 15:20                                             ` Michael Albinus
2008-05-05 18:26                                               ` Stefan Monnier
2008-04-21 19:29                                   ` Eli Zaretskii
2008-04-22 15:40                                     ` Michael Albinus
2008-01-27 20:43                 ` testing for a remote file to include file on a Windows mappeddrive Stefan Monnier
2008-01-29 15:46                   ` Michael Albinus
2008-01-30  6:15                     ` Richard Stallman
2008-01-30  7:43                       ` Michael Albinus
2008-01-30 14:24                         ` Stefan Monnier
2008-01-30 15:04                           ` Michael Albinus
2008-01-30 15:48                             ` Stefan Monnier
2008-01-30 16:04                               ` Michael Albinus
2008-01-30 17:49                                 ` Stefan Monnier
2008-01-30 16:04                           ` David Kastrup
2008-01-30 17:52                             ` Stefan Monnier
2008-01-30 19:50                               ` Michael Albinus
2008-01-30 21:33                                 ` Stefan Monnier
2008-01-31  9:07                                   ` Michael Albinus
2008-02-01 19:09                                     ` Stefan Monnier
2008-02-03 13:36                                       ` Michael Albinus
2008-02-04 21:55                                         ` Stefan Monnier
2008-02-05 15:52                                           ` Michael Albinus
2008-02-05 16:34                                             ` Stefan Monnier
2008-02-05 20:58                                               ` Michael Albinus
2008-02-05 22:21                                                 ` Stefan Monnier
2008-02-05 22:32                                                   ` Michael Albinus
2008-02-05 22:17                                               ` url-handler-file-remote-p (was: testing for a remote file to include file on a Windows mappeddrive) Michael Albinus
2008-02-06 14:44                                                 ` url-handler-file-remote-p Stefan Monnier
2008-02-06 20:37                                                   ` url-handler-file-remote-p Michael Albinus
2008-01-30 14:29                       ` testing for a remote file to include file on a Windows mappeddrive Stefan Monnier
2008-01-30 14:45                         ` Stefan Monnier
2008-01-31  1:05                         ` Richard Stallman
2008-01-31  1:56                           ` Stefan Monnier
2008-01-31 18:51                             ` Richard Stallman
2008-01-26 15:15           ` Jason Rumney
2008-04-21  4:25         ` Eric Hanchrow
2008-04-21  7:58           ` Andreas Schwab
2008-04-21  8:15             ` testing for a remote file to include file on aWindows mappeddrive Drew Adams
2008-04-21  8:48               ` Andreas Schwab
2008-04-21 17:08                 ` Drew Adams
2008-04-21 14:15               ` Stefan Monnier
2008-04-21 17:09                 ` Drew Adams
2008-04-21 17:52                   ` Stefan Monnier
2008-04-21 18:52                     ` Drew Adams
2008-04-21 19:24                       ` Stefan Monnier
2008-01-26  8:52   ` testing for a remote file to include file on a Windows mapped drive Eli Zaretskii
2008-01-25 22:11 ` Stefan Monnier
2008-01-26  8:50   ` Eli Zaretskii
2008-01-26 10:07 ` Eli Zaretskii
2008-01-26 16:55   ` Drew Adams
2008-01-26 17:26     ` Eli Zaretskii
2008-01-26 17:57       ` Drew Adams
2008-01-26 18:58         ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).