Fork me on GitHub
#leiningen
<
2018-04-24
>
sophiago01:04:42

is there a way to automate changing project names? i do this fairly frequently when i'm just noodling around and although it's really simple i've never not forgotten to change something the first time

hiredman19:04:14

the project name and the namespace names are orthogonal, they don't need to match

hiredman19:04:38

tools.namespace has some tools for changing namespace names, I've used them in the past, they seem to work

danielcompton02:04:30

what do you mean change a projects name?

danielcompton02:04:15

lets you deploy a fork under a different name

sophiago02:04:13

I mean, change essentially everything generated by a call to lein new app or similar: the defproject name, :main value, src dir, and ns in core.clj. That's the only way I can imagine to do it uniformally. Once some of that structure changes I can't think of how it would be possible

danielcompton02:04:30

ah, have never heard of anything that does that

danielcompton02:04:44

Other than recreating the template with a new name

sophiago02:04:26

I figured there wasn't given how often I've thought about this and possibly even asked about it before. The problem is it's fundamentally nondeterministic. As far as I can tell you'd have to rely on templates being unchanged, which would make it rather pointless