:type '(choice (const nil) string)
:group 'mail)
-(defcustom user-mail-address nil
+(defcustom user-mail-address (if command-line-processed
+ (concat (user-login-name) "@"
+ (or mail-host-address
+ (system-name)))
+ ;; Empty string means "not set yet".
+ "")
"*Full mailing address of this user.
This is initialized based on `mail-host-address',
after your init file is read, in case it sets `mail-host-address'."
(save-excursion
(set-buffer (get-buffer "*Messages*"))
(setq default-directory dir)))
+ ;; `user-full-name' is now known; reset its standard-value here.
+ (put 'user-full-name 'standard-value
+ (list (default-value 'user-full-name)))
;; For root, preserve owner and group when editing files.
(if (equal (user-uid) 0)
(setq backup-by-copying-when-mismatch t))
(setq user-init-file t)
(load user-init-file-1 t t)
- ;; If we did not find the user's init file,
- ;; set user-init-file conclusively to nil;
- ;; don't let it be set from default.el.
- (if (eq user-init-file t)
- (setq user-init-file user-init-file-1))
+ (when (eq user-init-file t)
+ ;; If we did not find ~/.emacs, try
+ ;; ~/.emacs.d/.emacs.
+ (let ((otherfile
+ (expand-file-name
+ (file-name-nondirectory user-init-file-1)
+ (file-name-as-directory
+ (expand-file-name
+ ".emacs.d"
+ (file-name-directory user-init-file-1))))))
+ (load otherfile t t)
+
+ ;; If we did not find the user's init file,
+ ;; set user-init-file conclusively.
+ ;; Don't let it be set from default.el.
+ (when (eq user-init-file t)
+ (setq user-init-file user-init-file-1))))
;; If we loaded a compiled file, set
;; `user-init-file' to the source version if that
(set-language-environment current-language-environment)))
;; Do this here in case the init file sets mail-host-address.
- (or user-mail-address
+ (if (equal user-mail-address "")
(setq user-mail-address (concat (user-login-name) "@"
(or mail-host-address
(system-name)))))
(insert-image img (propertize "xxx" 'help-echo help-echo
'keymap map)))
(insert "\n"))))
- (if (eq system-type 'gnu/linux)
- (fancy-splash-insert
- :face '(variable-pitch :foreground "red")
- "GNU Emacs is one component of a Linux-based GNU system.")
- (fancy-splash-insert
- :face '(variable-pitch :foreground "red")
+ (fancy-splash-insert
+ :face '(variable-pitch :foreground "red")
+ (if (eq system-type 'gnu/linux)
+ "GNU Emacs is one component of the GNU/Linux operating system."
"GNU Emacs is one component of the GNU operating system."))
(insert "\n")
(unless (equal (buffer-name fancy-splash-outer-buffer) "*scratch*")
;; each piece of output starts with one or two newlines
;; and does not end with any newlines.
(insert "Welcome to GNU Emacs")
- (if (eq system-type 'gnu/linux)
- (insert ", one component of a Linux-based GNU system."))
- (insert "\n")
+ (insert
+ (if (eq system-type 'gnu/linux)
+ ", one component of the GNU/Linux operating system.\n"
+ ", a part of the GNU operating system.\n"))
(unless (equal (buffer-name prev-buffer) "*scratch*")
(insert (substitute-command-keys