   ;; If none of these work for you, `conda-anaconda-home' must be set
   ;; explicitly. Afterwards, run M-x `conda-env-activate' to switch between
   ;; environments
-  (unless (cl-loop for dir in (list conda-anaconda-home
-                                    "~/.anaconda"
-                                    "~/.miniconda"
-                                    "~/.miniconda3"
-                                    "~/miniconda3"
-                                    "/usr/bin/anaconda3"
-                                    "/usr/local/anaconda3"
-                                    "/usr/local/miniconda3"
-                                    "/usr/local/Caskroom/miniconda/base")
-                   if (file-directory-p dir)
-                   return (setq conda-anaconda-home dir
-                                conda-env-home-directory dir))
-    (message "Cannot find Anaconda installation"))
+  (or (cl-loop for dir in (list conda-anaconda-home
+                                "~/.anaconda"
+                                "~/.miniconda"
+                                "~/.miniconda3"
+                                "~/miniconda3"
+                                "/usr/bin/anaconda3"
+                                "/usr/local/anaconda3"
+                                "/usr/local/miniconda3"
+                                "/usr/local/Caskroom/miniconda/base")
+               if (file-directory-p dir)
+               return (setq conda-anaconda-home dir
+                            conda-env-home-directory dir))
+      (message "Cannot find Anaconda installation"))
 
   ;; integration with term/eshell
   (conda-env-initialize-interactive-shells)



(use-package! pyimport
  :after python
  :config
  (map! :map python-mode-map
        :localleader
        (:prefix ("i" . "imports")
          :desc "Insert missing imports" "i" #'pyimport-insert-missing

    :documentation #'anaconda-mode-show-doc)
  (set-popup-rule! "^\\*anaconda-mode" :select nil)

  (defun +python-auto-kill-anaconda-processes-h ()
    "Kill anaconda processes if this buffer is the last python buffer."
    (when (and (eq major-mode 'python-mode)
