Okay, I'll take a look at it then.  I just wanted to make sure I wasn't missing 
something in the design that required it.

Thanks,
Jeremy

On Thursday, April 30, 2015 at 11:46:28 AM UTC-5, David Nolen wrote:
> It's the way it is because that's the way it was done nearly 4 years ago. If 
> people want to see it improved submit patches.
> 
> 
> David
> 
> 
> On Thu, Apr 30, 2015 at 11:21 AM, Jeremy Shoemaker <[email protected]> 
> wrote:
> Hi,
> 
> 
> 
> I started playing around with ClojureScript on NodeJS recently, and I was 
> looking at making a lein template for making CLI tools that would work with 
> npm so that the "binaries" end up in your path and can be used like any other 
> NodeJS CLI tool.
> 
> 
> 
> I ran into trouble quickly because it seems when you compile using :target 
> :nodejs, at runtime, it's expected that you set *main-cli-fn* to something.
> 
> 
> 
> In this case, I don't need that because I'm writing a wrapper JS file that 
> runs the tool and is specified in the "bin" section of the package.json file 
> that npm looks for.
> 
> 
> 
> It looks like it's trying to execute the main function as soon as I require 
> the compiled JS file.
> 
> 
> 
> My question is, why is this behaviour forced as it is?  It breaks what I'm 
> trying to do, but worse it seems to preclude the possibility of writing a 
> library that can be required into other NodeJS projects, even Javascript 
> projects.  It just seems to me that forcing this makes it harder to use 
> ClojureScript with the rest of the Javascript NodeJS ecosystem.  I don't see 
> how I could write a ClojureScript NodeJS library that can be used by someone 
> using Javascript on NodeJS.
> 
> 
> 
> Is there some way I can work around this limitation?  If you need example 
> code, I can provide some.
> 
> 
> 
> Thanks,
> 
> Jeremy
> 
> 
> 
> --
> 
> Note that posts from new members are moderated - please be patient with your 
> first post.
> 
> ---
> 
> You received this message because you are subscribed to the Google Groups 
> "ClojureScript" group.
> 
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> 
> To post to this group, send email to [email protected].
> 
> Visit this group at http://groups.google.com/group/clojurescript.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/clojurescript.

Reply via email to