Mercurial > emacs
comparison lisp/ange-ftp.el @ 4185:05a314aafd74
(file-name-handler-alist): Have two separate regexps with different hooks.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Tue, 20 Jul 1993 07:12:00 +0000 |
parents | cd2afb94d892 |
children | c050d8a0c3db |
comparison
equal
deleted
inserted
replaced
4184:4a40e0433bf9 | 4185:05a314aafd74 |
---|---|
854 | 854 |
855 ;;;; ------------------------------------------------------------ | 855 ;;;; ------------------------------------------------------------ |
856 ;;;; Internal variables. | 856 ;;;; Internal variables. |
857 ;;;; ------------------------------------------------------------ | 857 ;;;; ------------------------------------------------------------ |
858 | 858 |
859 (defconst ange-ftp-version "$Revision: 1.29 $") | 859 (defconst ange-ftp-version "$Revision: 1.30 $") |
860 | 860 |
861 (defvar ange-ftp-data-buffer-name " *ftp data*" | 861 (defvar ange-ftp-data-buffer-name " *ftp data*" |
862 "Buffer name to hold directory listing data received from ftp process.") | 862 "Buffer name to hold directory listing data received from ftp process.") |
863 | 863 |
864 (defvar ange-ftp-netrc-modtime nil | 864 (defvar ange-ftp-netrc-modtime nil |
3748 (let (file-name-handler-alist) | 3748 (let (file-name-handler-alist) |
3749 (apply operation args))))) | 3749 (apply operation args))))) |
3750 | 3750 |
3751 | 3751 |
3752 ;;; This regexp takes care of real ange-ftp file names (with a slash | 3752 ;;; This regexp takes care of real ange-ftp file names (with a slash |
3753 ;;; and colon), and absolute filenames with only one component, for | 3753 ;;; and colon). |
3754 ;;; the sake of hostname completion. | |
3755 ;;;###autoload | 3754 ;;;###autoload |
3756 (or (assoc "^/[^/:]*\\([^/:]:\\|\\'\\)" file-name-handler-alist) | 3755 (or (assoc "^/[^/:]*[^/:]:" file-name-handler-alist) |
3757 (setq file-name-handler-alist | 3756 (setq file-name-handler-alist |
3758 (cons '("^/[^/:]*\\([^/:]:\\|\\'\\)" . ange-ftp-hook-function) | 3757 (cons '("^/[^/:]*[^/:]:" . ange-ftp-hook-function) |
3758 file-name-handler-alist))) | |
3759 | |
3760 ;;; This regexp recognizes and absolute filenames with only one component, | |
3761 ;;; for the sake of hostname completion. | |
3762 ;;;###autoload | |
3763 (or (assoc "^/[^/:]*\\'" file-name-handler-alist) | |
3764 (setq file-name-handler-alist | |
3765 (cons '("^/[^/:]*\\'" . ange-ftp-completion-hook-function) | |
3759 file-name-handler-alist))) | 3766 file-name-handler-alist))) |
3760 | 3767 |
3761 ;;; The above two forms are sufficient to cause this file to be loaded | 3768 ;;; The above two forms are sufficient to cause this file to be loaded |
3762 ;;; if the user ever uses a file name with a colon in it. | 3769 ;;; if the user ever uses a file name with a colon in it. |
3763 | 3770 |