Code Monkey home page Code Monkey logo

Comments (12)

emezeske avatar emezeske commented on June 24, 2024

Hmm, that definitely sounds like a problem. I would have expected the lein run task to internally call the lein compile task, thereby compiling the ClojureScript code. I'll take a look at Leiningen to see if this is the case, or of not, how best to ensure that things are compiled before running.

from lein-cljsbuild.

zentrope avatar zentrope commented on June 24, 2024

Hm. I might have mixed things up a bit. If I do the following (on a fresh new checkout of my project):

lein deps
lein run

the clojurescript files are properly compiled. However:

lein deps
lein trampoline run ;; with or without a :main (or whatever)

does not compile the clojurescript. So maybe what I'm asking for is a hook on the trampoline task?

Even more data points: With a fresh project:

lein run

or

lein trampoline run

will pull in the deps (without me having to do the extra preliminary step), but if I do lein run using that method (skipping lein deps) the clojurescript compiler is not invoked.

from lein-cljsbuild.

brigham avatar brigham commented on June 24, 2024

I have the same issue.

Running:

lein run WHATEVER

does correctly compile the cljs files.

But:

lein trampoline run WHATEVER

does output "Compiling ClojureScript," however there are no further logs and no files appear in the output location.

from lein-cljsbuild.

cemerick avatar cemerick commented on June 24, 2024

Is this still a problem?

from lein-cljsbuild.

magomimmo avatar magomimmo commented on June 24, 2024

This new feature request could be associated in some way with "my" need to be able to optionally pass a cljsbuild build-id to lein compile in such a way that I could compile just one build at the time, instead of being forced to compile them all.
e.g. lein compile dev

from lein-cljsbuild.

cemerick avatar cemerick commented on June 24, 2024

@magomimmo Sounds like you need to split your builds up into different leiningen profiles? Then you would use lein with-profile $SOME_PROFILE cljsbuild once or similar…

from lein-cljsbuild.

magomimmo avatar magomimmo commented on June 24, 2024

Yes, it could be a workaround, but IMHO any CLJS project using cljsbuild eventually requires more builds, at least one for each Google Closure Optimization). Any not so simple project.clj including cljsbuild (which means crossover, clix, cljs unit-test, etc.) is so dense that's difficult to be read and easily maintained.

By adding a build-id to the hooks, at least we can a more moderate mass of information to be read and maintained. But its just my opinion.

On Sep 12, 2013, at 2:19 PM, Chas Emerick [email protected] wrote:

@magomimmo Sounds like you need to split your builds up into different leiningen profiles? Then you would use lein with-profile $SOME_PROFILE cljsbuild once or similar…


Reply to this email directly or view it on GitHub.

from lein-cljsbuild.

cemerick avatar cemerick commented on June 24, 2024

I definitely think the configuration can be slimmed down some, and that's something I want to pursue for 2.x. But, adding build IDs is going in exactly the opposite direction! :-) In any case, it's a separate topic from this issue.

No one has replied in two weeks since I triaged this originally, so closing now.

from lein-cljsbuild.

magomimmo avatar magomimmo commented on June 24, 2024

yes, I agree to close it.

Is there somewhere a kind of "specification requirement" for the 2.x? As soon as I better understand the concept of release in lein I'll try to mitigate the use of build-id. I'll go through your repos to see if I can grasp something…..

thanks

On Sep 13, 2013, at 4:14 AM, Chas Emerick [email protected] wrote:

I definitely think the configuration can be slimmed down some, and that's something I want to pursue for 2.x. But, adding build IDs is going in exactly the opposite direction! :-) In any case, it's a separate topic from this issue.

No one has replied in two weeks since I triaged this originally, so closing now.


Reply to this email directly or view it on GitHub.

from lein-cljsbuild.

cemerick avatar cemerick commented on June 24, 2024

The only "specification" for 2.x so far is "any breaking change w.r.t. <= 1.x". :-) More seriously, significant new features can hold for 2.x so cljsbuild can get a 1.0 release behind it/us.

from lein-cljsbuild.

cemerick avatar cemerick commented on June 24, 2024

@magomimmo I had totally blanked on the fact that you already can provide build IDs and use them to perform selective compilations:

https://github.com/emezeske/lein-cljsbuild/blob/master/README.md#multiple-build-configurations

Sorry about that. :-)

from lein-cljsbuild.

magomimmo avatar magomimmo commented on June 24, 2024

@cemerick: no problem at all. I'm still learning to put together the various pieces. Sometimes I feel a bit of incidental complexity of the environment, but I can leave with it.

On Sep 15, 2013, at 1:06 PM, Chas Emerick [email protected] wrote:

@magomimmo I had totally blanked on the fact that you already can provide build IDs and use them to perform selective compilations:

https://github.com/emezeske/lein-cljsbuild/blob/master/README.md#multiple-build-configurations

Sorry about that. :-)


Reply to this email directly or view it on GitHub.

from lein-cljsbuild.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.