Mercurial > emacs
changeset 7022:5635564a3064
(command-line-default-directory): New variable.
(command-line, command-line-1): Use and set it.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Fri, 22 Apr 1994 18:28:22 +0000 |
parents | da5dc735eb50 |
children | a326806e4752 |
files | lisp/startup.el |
diffstat | 1 files changed, 7 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/startup.el Fri Apr 22 08:49:57 1994 +0000 +++ b/lisp/startup.el Fri Apr 22 18:28:22 1994 +0000 @@ -87,6 +87,10 @@ processes `argi'. If it does so, it may consume successive arguments by altering `command-line-args-left' to remove them.") +(defvar command-line-default-directory nil + "Default directory to use for command line arguments. +This is normally copied from `default-directory' when Emacs starts.") + (defvar before-init-hook nil "Functions to call after handling urgent options but before init files. The frame system uses this to open frames to display messages while @@ -177,6 +181,8 @@ (run-hooks 'window-setup-hook))))) (defun command-line () + (setq command-line-default-directory default-directory) + ;; See if we should import version-control from the environment variable. (let ((vc (getenv "VERSION_CONTROL"))) (cond ((eq vc nil)) ;don't do anything if not set @@ -423,7 +429,7 @@ (set-buffer (get-buffer "*scratch*")) (erase-buffer) (set-buffer-modified-p nil))))) - (let ((dir default-directory) + (let ((dir command-line-default-directory) (file-count 0) first-file-buffer (line 0))