diff options
author | Bozhidar Batsov <bozhidar@batsov.com> | 2015-08-13 12:13:17 +0300 |
---|---|---|
committer | Bozhidar Batsov <bozhidar@batsov.com> | 2015-08-13 12:13:17 +0300 |
commit | fe4acded4c925785bcb9afdb422da6d2e646aec3 (patch) | |
tree | a2ddf22c1d1ade17f1fdea748db13bae12bb78eb /cider.el | |
parent | 2d89c29e9de9798f7c1db635c18d34fdb8786e67 (diff) |
Make it possible to suppress the project prompt when doing cider-connect
Diffstat (limited to 'cider.el')
-rw-r--r-- | cider.el | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -61,6 +61,12 @@ :link '(url-link :tag "Github" "https://github.com/clojure-emacs/cider") :link '(emacs-commentary-link :tag "Commentary" "cider")) +(defcustom cider-prompt-for-project-on-connect t + "Controls whether to prompt for associated project on `cider-connect'." + :type 'boolean + :group 'cider + :package-version '(cider . "0.10.0")) + (require 'cider-client) (require 'cider-interaction) (require 'cider-eldoc) @@ -264,7 +270,8 @@ Create REPL buffer and start an nREPL client connection." (let ((nrepl-create-client-buffer-function #'cider-repl-create) (nrepl-use-this-as-repl-buffer repl-buff)) (nrepl-start-client-process host port) - (when (y-or-n-p "Do you want to associate the new connection with a local project? ") + (when (and cider-prompt-for-project-on-connect + (y-or-n-p "Do you want to associate the new connection with a local project? ")) (cider-assoc-project-with-connection nil (nrepl-default-connection-buffer)))))) |