I'll try it today and let you know by the end of today if I can manage it :)
Luc P. Phil Hagelberg <p...@hagelb.org> wrote .. > On Thu, Aug 26, 2010 at 5:59 PM, <lprefonta...@softaddicts.ca> wrote: > > Instead I decided to experiment a Leiningen plug in, sauberjar to create the > > target only with the class files and only the ones for which there is a > > corresponding source file in the source folder. To start this asap, I cloned > the > > existing jar task however I feel I can confine the modification to a single > > function. > > > > I just need to filter the list of files to dump in the jar target before > > creating the jar. > > > > Phil, I would rather see this in the jar task rather than having a separate > > plug in. > > I'm hoping get the problem fixed in Clojure itself rather than working > around it in Leiningen. However, in the mean time a better fix could > be done in a plugin using hooks. The hook would wrap the compile task > to delete all the files you don't want after the compile task has run. > It would look something like this (rough sketch, haven't run this, > only proven it correct, etc.): > > (defn our-classes-only [compile-task project & args] > (apply compile-task project args) > (doseq [f (file-seq (java.io.File. (:compile-path project))) > :when (and (.isFile f) (not (has-corresponding-src? f)))] > (.delete f))) > > (add-hook #'leiningen.compile/compile our-classes-only) > > -Phil > > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to clojure@googlegroups.com > Note that posts from new members are moderated - please be patient with your > first > post. > To unsubscribe from this group, send email to > clojure+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en