From 76af63ad85f3e7e96c9ce38353896ed50aeea553 Mon Sep 17 00:00:00 2001 From: Jeremy Dormitzer Date: Sun, 14 Jun 2020 12:27:06 -0400 Subject: [PATCH] Remove flycheck-clojure setup call and old clj format function --- emacs/init.org | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/emacs/init.org b/emacs/init.org index e461f40..afdfab3 100755 --- a/emacs/init.org +++ b/emacs/init.org @@ -3256,7 +3256,6 @@ Sprinkle in some CIDER: '(("local" "localhost" "4005")) cider-prompt-for-symbol nil) (general-def cider-mode-map "C-c t" cider-test-commands-map) - (flycheck-clojure-setup) (add-hook 'cider-repl-mode-hook 'smartparens-strict-mode) :hook ((clojure-mode . cider-mode) (clojurescript-mode . cider-mode) @@ -3291,35 +3290,6 @@ Clj-refactor adds magical refactoring abilities: :hook ((clojure-mode . clj-refactor-setup))) #+END_SRC -Integrate with cljfmt, the Clojure code formatter: -#+BEGIN_SRC emacs-lisp - (defun cljfmt () - (interactive) - (let* ((start (if (use-region-p) (region-beginning) (point-min))) - (end (if (use-region-p) (region-end) (point-max))) - (text (buffer-substring start end)) - (file (make-temp-file "cljfmt")) - (fmted - (with-temp-buffer - (insert text) - (write-file file) - (shell-command - (concat - "clojure " - "-Sdeps " - "'{:aliases {:fmt {:extra-deps {cljfmt {:mvn/version \"0.6.4\"}} :main-opts [\"-m\" \"cljfmt.main\"]}}}' " - "-A:fmt " - "fix " - file)) - (revert-buffer nil t) - (buffer-substring (point-min) (point-max))))) - (delete-region start end) - (goto-char start) - (insert fmted))) - - (general-def clojure-mode-map "C-M-\\" #'cljfmt) -#+END_SRC - Add support for running Org-mode Clojure source blocks with [[https://github.com/borkdude/babashka][Babashka]]: #+BEGIN_SRC emacs-lisp (with-eval-after-load 'ob-clojure