X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/51db08ebe0de202fa87befb0b528372b64edc530..dfc9a078920aaa69c75b712a9199f38db6c13de4:/lisp/startup.el diff --git a/lisp/startup.el b/lisp/startup.el index da05912d92..32021225e7 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -1,7 +1,7 @@ ;;; startup.el --- process Emacs shell arguments ;; Copyright (C) 1985, 1986, 1992, 1994, 1995, 1996, 1997, 1998, 1999, 2000, -;; 2001, 2002, 2004, 2005 Free Software Foundation, Inc. +;; 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. ;; Maintainer: FSF ;; Keywords: internal @@ -984,7 +984,13 @@ or `CVS', and any subdirectory that contains a file named `.nosearch'." (setq term (if (setq hyphend (string-match "[-_][^-_]+$" term)) (substring term 0 hyphend) - nil))))) + nil))) + (when term + ;; The terminal file has been loaded, now call the terminal + ;; specific initialization function. + (let ((term-init-func (intern (concat "terminal-init-" term)))) + (when (fboundp term-init-func) + (funcall term-init-func)))))) ;; Update the out-of-memory error message based on user's key bindings ;; for save-some-buffers. @@ -1629,6 +1635,15 @@ normal otherwise." (setq file file-ex)) (load file nil t))) + ;; This is used to handle -script. It's not clear + ;; we need to document it. + ((member argi '("-scriptload")) + (let* ((file (command-line-normalize-file-name + (or argval (pop command-line-args-left)))) + ;; Take file from default dir. + (file-ex (expand-file-name file))) + (load file-ex nil t t))) + ((equal argi "-insert") (setq tem (or argval (pop command-line-args-left))) (or (stringp tem) @@ -1709,11 +1724,7 @@ normal otherwise." ;; Maybe display a startup screen. (unless (or inhibit-startup-message noninteractive - emacs-quick-startup - ;; Don't display startup screen if init file - ;; has started some sort of server. - (and (fboundp 'process-list) - (process-list))) + emacs-quick-startup) ;; Display a startup screen, after some preparations. ;; If there are no switches to process, we might as well