bin/doom: add -y/--yes option

This commit is contained in:
Henrik Lissner 2018-05-24 16:02:57 +02:00
parent 499630fdcd
commit 8a7ebebf16
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -30,7 +30,8 @@
(format! (bold "Options:\n")) (format! (bold "Options:\n"))
" -d --debug\t\tTurns on doom-debug-mode (and debug-on-error)\n" " -d --debug\t\tTurns on doom-debug-mode (and debug-on-error)\n"
" -e --emacsd DIR\tUse the emacs config at DIR (e.g. ~/.emacs.d)\n" " -e --emacsd DIR\tUse the emacs config at DIR (e.g. ~/.emacs.d)\n"
" -p --private DIR\tUse the private module at DIR (e.g. ~/.doom.d)\n\n") " -p --private DIR\tUse the private module at DIR (e.g. ~/.doom.d)\n"
" -y --yes\t\tAuto-accept all confirmation prompts\n\n")
(princ (buffer-string))) (princ (buffer-string)))
(doom--dispatch-help)) (doom--dispatch-help))
@ -50,8 +51,8 @@
(setq emacs-dir (expand-file-name (pop argv))) (setq emacs-dir (expand-file-name (pop argv)))
(or (file-directory-p emacs-dir) (or (file-directory-p emacs-dir)
(error "%s does not exist" emacs-dir))) (error "%s does not exist" emacs-dir)))
("--") ((or "-y" "--yes")
(_))) (setq doom-auto-accept t))))
;; Bootstrap Doom ;; Bootstrap Doom
(load (expand-file-name "init" emacs-dir) (load (expand-file-name "init" emacs-dir)