Emacs: Command Line Options
here's the most useful emacs command line options.
Do Not Load Init
--no-init-fileor-q-
Do not load Emacs Init File, nor global users init
default.el. --no-site-file-
Do not load the site-wide init file site-start.el
-Qor--quick-
same as
--no-init-file --no-site-file --no-splash.
Load a Different Init
emacs -q -l InitFilePath-
load a different init.
Debug Init
emacs --debug-init-
Start emacs to catch possible error in init.
Start emacs without loading previously opened files
--no-desktop-
start emacs without loading previously opened files. 〔see Emacs Init: Restore Opened Files (desktop-save-mode)〕
this is useful when you have a corrupt desktop file.
Load Emacs Lisp Files
--load=pathor-l path- Run the elisp file at path.
--batch-
- Do not launch emacs as a editor.
- Do not load user init.
- Usually used together with
--load
--script path-
same as
--batchand--load
Start emacs in terminal
--no-window-systemor-nw-
start emacs in terminal.