diff --git a/emacs/init.org b/emacs/init.org index 8d9125b..012c08e 100755 --- a/emacs/init.org +++ b/emacs/init.org @@ -4793,10 +4793,10 @@ A package that bundles together common code beautifying tools for many languages (leader-def-key "cf" 'format-all-buffer) :config (with-eval-after-load 'lsp-mode - (add-hook 'format-all-after-format-functions - (lambda (formatter status) - (when lsp-mode - (lsp-restart-workspace)))))) + (add-hook 'format-all-after-format-functions + (lambda (formatter status) + (when (and (eq status :reformatted) python-mode lsp-mode) + (lsp-restart-workspace)))))) #+END_SRC * Compiling