   (:map clojure-mode-map
         (("C-x c f" .  lk/clojure-format-current-buffer)
          ("C-x c v" . lk/clojure-check-current-buffer)
+         ("C-x c p" . lk/clojure-check-project)
          ("C-x c s" . lk/clojure-scratch)
          ("C-x c j" . monroe-nrepl-server-start))))
 

  (interactive)
  (lk/invoke-compile-tool-in-project "project.clj" "lein cljfmt fix %s"))

(defun lk/clojure-check-current-buffer ()
  "Format current buffer with clj-kondo - assume it's installed already
     (it is as it was added to ~/.lein/profiles.clj)"
  (interactive)
  (lk/invoke-compile-tool-in-project "project.clj" "clj-kondo --lint %s"))

(defun lk/clojure-slamhound-current-buffer ()
  "Infer imports for current file via slamhound - assume it's installed already
     (it is as it was added to ~/.lein/profiles.clj)"

     (format "docker run -v %s/src:/src --rm borkdude/clj-kondo clj-kondo --lint src" dir)
     'compilation-mode)))

(defun lk/clojure-check-current-buffer ()
  "Format current buffer with clj-kondo - assume it's installed already
     (it is as it was added to ~/.lein/profiles.clj)"
  (interactive)
  (let* ((dir  (locate-dominating-file default-directory "project.clj"))
         (cmd-string (format "docker run -v %s/src:/src --rm borkdude/clj-kondo clj-kondo --lint %s" dir "%s")))
    (lk/invoke-compile-tool-in-project "project.clj" cmd-string)))

(use-package clojure-mode-extra-font-locking
  :ensure t)

