Unset command line options irrelevant to the current OS
This commit is contained in:
@@ -57,6 +57,8 @@ git clone https://github.com/jamescherti/minimal-emacs.d ~/.emacs.d
|
|||||||
- Disables warnings from the legacy advice API and suppresses warnings about aliased variables.
|
- Disables warnings from the legacy advice API and suppresses warnings about aliased variables.
|
||||||
- Avoids unnecessary excessive UI updates.
|
- Avoids unnecessary excessive UI updates.
|
||||||
- Disables font compacting to avoid high memory usage.
|
- Disables font compacting to avoid high memory usage.
|
||||||
|
- Defer tool bar setup
|
||||||
|
- Unset command line options irrelevant to the current OS
|
||||||
|
|
||||||
2. **Native Compilation and Byte Compilation:**
|
2. **Native Compilation and Byte Compilation:**
|
||||||
- Configures native compilation and byte compilation settings
|
- Configures native compilation and byte compilation settings
|
||||||
|
|||||||
@@ -195,7 +195,15 @@
|
|||||||
;; Shave seconds off startup time by starting the scratch buffer in
|
;; Shave seconds off startup time by starting the scratch buffer in
|
||||||
;; `fundamental-mode'
|
;; `fundamental-mode'
|
||||||
(setq initial-major-mode 'fundamental-mode
|
(setq initial-major-mode 'fundamental-mode
|
||||||
initial-scratch-message nil)))
|
initial-scratch-message nil)
|
||||||
|
|
||||||
|
(unless minimal-emacs-debug
|
||||||
|
;; Unset command line options irrelevant to the current OS. These options
|
||||||
|
;; are still processed by `command-line-1` but have no effect.
|
||||||
|
(unless (eq system-type 'darwin)
|
||||||
|
(setq command-line-ns-option-alist nil))
|
||||||
|
(unless (memq initial-window-system '(x pgtk))
|
||||||
|
(setq command-line-x-option-alist nil)))))
|
||||||
|
|
||||||
;;; Native compilation and Byte compilation
|
;;; Native compilation and Byte compilation
|
||||||
|
|
||||||
@@ -235,14 +243,15 @@
|
|||||||
(unless (memq window-system '(mac ns))
|
(unless (memq window-system '(mac ns))
|
||||||
(setq menu-bar-mode nil)))
|
(setq menu-bar-mode nil)))
|
||||||
|
|
||||||
(unless noninteractive
|
(unless (daemonp)
|
||||||
;; Temporarily override the tool-bar-setup function to prevent it from
|
(unless noninteractive
|
||||||
;; running during the initial stages of startup
|
;; Temporarily override the tool-bar-setup function to prevent it from
|
||||||
(advice-add #'tool-bar-setup :override #'ignore)
|
;; running during the initial stages of startup
|
||||||
(define-advice startup--load-user-init-file
|
(advice-add #'tool-bar-setup :override #'ignore)
|
||||||
(:before (&rest _) minimal-emacs-setup-toolbar)
|
(define-advice startup--load-user-init-file
|
||||||
(advice-remove #'tool-bar-setup #'ignore)
|
(:before (&rest _) minimal-emacs-setup-toolbar)
|
||||||
(tool-bar-setup)))
|
(advice-remove #'tool-bar-setup #'ignore)
|
||||||
|
(tool-bar-setup))))
|
||||||
(when minimal-emacs-disable-tool-bar
|
(when minimal-emacs-disable-tool-bar
|
||||||
(push '(tool-bar-lines . 0) default-frame-alist)
|
(push '(tool-bar-lines . 0) default-frame-alist)
|
||||||
(setq tool-bar-mode nil))
|
(setq tool-bar-mode nil))
|
||||||
|
|||||||
Reference in New Issue
Block a user