Fork me on GitHub
#beginners
<
2016-06-15
>
swizzard14:06:31

holy wow @dmbennett that string-interpolation stuff is A+++, thanks for alerting me to it

jeff.engebretsen17:06:19

Can you give an example of what you mean?

dmbennett18:06:26

@jeff.engebretsen: what are you referring to?

jeff.engebretsen18:06:21

Nothing I guess..

dmbennett19:06:41

does anyone know how to add a function to lein in such a way that all lein repls can call that function?

dmbennett19:06:11

Say I want to have this macro available anytime I repl

(defmacro valid-args?
  "returns a list of args for given function"
  [function-name]
  `(:arglists (meta (var ~function-name))))

seancorfield19:06:46

(with Boot, you’d put such "global" functions/macros in your ~/.boot/profile.boot file)

Tim23:06:20

if I have an input like ("bar" "foo" "train" "cousin”) and I would like an output like ["barfoo" "traincousin”], how could I build a function that does this?

cory23:06:35

@tmtwd how about

(mapv clojure.string/join (partition 2 '("bar" "foo" "train" "cousin")))