clojure-emacs/cider — pull request #544 by AdamClements (2014-04-29 14:15:43+00:00)
Title: Add cider-jack-in-with-profile

I have a cross platform leiningen project with multiple profiles, for which I need to have repls which start with different profiles. At the moment I have to do `lein with-profile :local-test repl :headless` manually which leaves a terminal floating around separate to my emacs window, and also leaves me not knowing which terminals are linked to which emacs windows.

I've proposed a cider-jack-in-with-profile interactive function, as cider-jack-in already had an optional parameter and so couldn't be overridden. This duplicated most of cider-jack-in and so I have split out the common functionality, cider-jack-in should be functionally unaffected.

Please feel free to advise on style and appropriate locations for functions. I needed to make cider-server-command more flexible and so moved it into a function, which means that the locate-file might need to happen more than once, but a jack-in is a relatively infrequent action anyway, so I don't know how much this matters.