From: Michael Albinus Date: Sat, 7 Jul 2007 11:17:51 +0000 (+0000) Subject: * simple.el (start-file-process): New defun. X-Git-Tag: emacs-pretest-23.0.90~12022 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=7cb76caa9cdf5c046c5c7d98b0fdc413566dd9e6;p=emacs.git * simple.el (start-file-process): New defun. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fc0c6556026..b4026579859 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2007-07-07 Michael Albinus + + * simple.el (start-file-process): New defun. + 2007-07-07 Stefan Monnier * files.el (find-file-confirm-nonexistent-file): Rename from diff --git a/lisp/simple.el b/lisp/simple.el index a0915b9f8ed..c052ce3574b 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -2202,6 +2202,18 @@ value passed." (when stderr-file (delete-file stderr-file)) (when lc (delete-file lc))))) +(defun start-file-process (name buffer program &rest program-args) + "Start a program in a subprocess. Return the process object for it. +Similar to `start-process', but may invoke a file handler based on +`default-directory'. The current working directory of the +subprocess is `default-directory'. + +PROGRAM and PROGRAM-ARGS might be file names. They are not +objects of file handler invocation." + (let ((fh (find-file-name-handler default-directory 'start-file-process))) + (if fh (apply fh 'start-file-process name buffer program program-args) + (apply 'start-process name buffer program program-args)))) + (defvar universal-argument-map