Thanks for clearing up what you are asking for.
Leiningen has a feature called :injections which you can combine with vinyasa to get this effect If you put something like this in your leiningen profile:
~/lein/profiles.clj:
{:user {:plugins []
:dependencies [[im.chit/vinyasa "0.1.8"]]
:injections [(require 'vinyasa.inject)
(vinyasa.inject/inject
'clojure.core '>
'[[clojure.repl doc source]
[clojure.pprint pprint pp]])]}}
Because this is in your profiles.clj it only affects you. Other people who work on the project won't be affected.
Because injecting into clojure.core strikes me as a little iffy, I follow the vinyasa author's advice and inject into a namespace called . which is crated by my profile for every project I work on. This namespace always exists which makes these function work even in newly created namespaces that don't yet refer clojure.core.
My ~/.lein/profiles.clj:
{:user
{:plugins []
:dependencies [[spyscope "0.1.4"]
[org.clojure/tools.namespace "0.2.4"]
[io.aviso/pretty "0.1.8"]
[im.chit/vinyasa "0.4.7"]]
:injections
[(require 'spyscope.core)
(require '[vinyasa.inject :as inject])
(require 'io.aviso.repl)
(inject/in ;; the default injected namespace is `.`
;; note that `:refer, :all and :exclude can be used
[vinyasa.inject :refer [inject [in inject-in]]]
[clojure.pprint :refer [pprint]]
[clojure.java.shell :refer [sh]]
[clojure.repl :refer [doc source]]
[vinyasa.maven pull]
[vinyasa.reflection .> .? .* .% .%> .& .>ns .>var])]}}
which works like this:
hello.core> (./doc first)
-------------------------
clojure.core/first
([coll])
Returns the first item in the collection. Calls seq on its
argument. If coll is nil, returns nil.
nil
hello.core> (in-ns 'new-namespace)
#namespace[new-namespace]
new-namespace> (./doc first)
nil
new-namespace> (clojure.core/refer-clojure)
nil
new-namespace> (./doc first)
-------------------------
clojure.core/first
([coll])
Returns the first item in the collection. Calls seq on its
argument. If coll is nil, returns nil.
nil