.emacs.d

My Emacs configuration files.
Log | Files | Refs | README

commit 8eba7ccbc42e1df9911d79c15d77eed7f270d3a9
parent a6b013c6328f458bbbef9429a2437f350cfb37f4
Author: Hugo Soucy <hugo.soucy@toumoro.com>
Date:   Thu, 19 Nov 2020 09:20:43 -0500

Remove indentation defuns

Diffstat:
Mpartials/lua.el | 23+----------------------
1 file changed, 1 insertion(+), 22 deletions(-)

diff --git a/partials/lua.el b/partials/lua.el @@ -1,25 +1,4 @@ (use-package lua-mode ;; a major-mode for editing Lua scripts. :ensure t - :pin melpa - :config - ;; Fixing indentation of lua (busted) in emacs. A nasty hack - (defun lua-busted-fuckups-fix () - (save-excursion - (lua-forward-line-skip-blanks 'back) - (let* ((current-indentation (current-indentation)) - (line (thing-at-point 'line t)) - (busted-p (s-matches? - (rx (+ bol (* space) - (or "context" "describe" "it" "setup" "teardown") - "(")) - line))) - (when busted-p - (+ current-indentation lua-indent-level))))) - - (defun rgc-lua-calculate-indentation-override (old-function &rest arguments) - (or (lua-busted-fuckups-fix) - (apply old-function arguments))) - - (advice-add #'lua-calculate-indentation-override - :around #'rgc-lua-calculate-indentation-override)) + :pin melpa)