emacs: re-enable electric-indent-mode

This commit is contained in:
Jeremy Baxter 2024-04-27 19:29:21 +12:00
parent 94ca1efc4e
commit d6a3439341

View file

@ -52,8 +52,6 @@ One will be created if none exist."
;; hooks ;; hooks
(defun indent-common-hook () (defun indent-common-hook ()
;; turn off smart indent
(electric-indent-mode -1)
;; set indent width to 4 spaces ;; set indent width to 4 spaces
(setq tab-width 4 (setq tab-width 4
c-basic-offset 4 c-basic-offset 4
@ -264,6 +262,34 @@ One will be created if none exist."
" " (:eval (breadcrumb-project-crumbs)) " " (:eval (breadcrumb-project-crumbs))
" : " (:eval (breadcrumb-imenu-crumbs)))))) " : " (:eval (breadcrumb-imenu-crumbs))))))
;; dashboard
(package-install 'dashboard)
(defun make-quote ()
(interactive)
(let ((quotes
'("At its core is an interpreter for Emacs Lisp."
"\"only one segfault in the default install, in a heck of a long time!\""
"Merely an interface to your code."
"M-x eglot"
"50 years and Dired is still the best file manager on the planet"
(concat "Welcome home, " user-login-name))))
(nth (random (length quotes)) quotes)))
(setq dashboard-banner-logo-title "Welcome to GNU Emacs, one component of the GNU/Linux operating system."
dashboard-startup-banner "~/pix/jemacs-book.png"
dashboard-center-content t
dashboard-vertically-center-content t
dashboard-items
'((bookmarks . 8)
(recents . 4))
dashboard-footer-messages `(,(make-quote))
initial-buffer-choice (lambda () (get-buffer-create dashboard-buffer-name)))
(add-hook 'after-init-hook 'dashboard-insert-startupify-lists)
(add-hook 'after-init-hook 'dashboard-initialize)
(dashboard-setup-startup-hook)
;; misc ;; misc
;; guess the major mode from file name ;; guess the major mode from file name