Emacs: Install and use dtrt-indent-mode
Alan Pearce alan.pearce@spotcap.com
Tue, 25 Aug 2015 16:56:05 +0200
2 files changed, 15 insertions(+), 0 deletions(-)
M tag-emacs/emacs.d/Cask → tag-emacs/emacs.d/Cask
@@ -33,6 +33,7 @@ (depends-on "dired-k") (depends-on "dired-subtree") (depends-on "discover") (depends-on "discover-my-major") +(depends-on "dtrt-indent") (depends-on "elisp-slime-nav") (depends-on "emmet-mode") (depends-on "epl")
M tag-emacs/emacs.d/init.org → tag-emacs/emacs.d/init.org
@@ -615,6 +615,20 @@ (add-hook 'php-mode-hook (lambda () (smart-tabs-mode indent-tabs-mode))))) #+END_SRC +** dtrt-indent-mode + +Sometimes people use different indentation settings. [[https://github.com/jscheid/dtrt-indent][dtrt-indent]] +guesses the correct settings for me. + +#+BEGIN_SRC emacs-lisp + (req-package dtrt-indent + :init (dtrt-indent-mode 1) + :config (progn + (defadvice dtrt-indent-try-set-offset (after toggle-smart-tabs activate) + (message "setting smart-tabs-mode") + (smart-tabs-mode (or indent-tabs-mode -1))))) +#+END_SRC + * Security ** password-store