Re: Namespaces in waiting
You can use find-namespaces from http://clojure.github.io/tools.namespace/#clojure.tools.namespace.find to + clojure.java.classpath to get a list of all namespaces in current classpath... On Mon, Jan 6, 2014 at 7:45 PM, Stephen C. Gilardi scgila...@gmail.comwrote: On Jan 1, 2014, at 3:26 PM, Dave Tenny dave.te...@gmail.com wrote: When I use 'lein repl' in some project context and get to the REPL prompt, there's an available but as yet not ... present ... namespace, i.e. (all-ns) won't list the namespace(s) created in the lein project directory tree. Is there some API I can use to see a list these available but not active namespaces? I’m not aware of one. I'm guessing that looking at what's on the class path doesn't necessarily tell me what namespaces might be USE-able via (use 'x). Walking the classpath including the contents of jar files would be a way to construct such a list of USE-able (or REQUIRE-able) namespaces. It would involve traversing the directory structure under each entry in the classpath and reading at least the first ns form in each candidate file (or jar entry). —Steve -- -- 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 unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- With best wishes,Alex Ott http://alexott.net/ Twitter: alexott_en (English), alexott (Russian) Skype: alex.ott -- -- 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 unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: Namespaces in waiting
Thanks for the pointer. This appears to work solely off the clojure source and may be very useful. It raises all kinds of non-namespace-related questions for me though that I'll ask in another topic. On Tue, Jan 7, 2014 at 9:02 AM, Alex Ott alex...@gmail.com wrote: You can use find-namespaces from http://clojure.github.io/tools.namespace/#clojure.tools.namespace.find to + clojure.java.classpath to get a list of all namespaces in current classpath... On Mon, Jan 6, 2014 at 7:45 PM, Stephen C. Gilardi scgila...@gmail.comwrote: On Jan 1, 2014, at 3:26 PM, Dave Tenny dave.te...@gmail.com wrote: When I use 'lein repl' in some project context and get to the REPL prompt, there's an available but as yet not ... present ... namespace, i.e. (all-ns) won't list the namespace(s) created in the lein project directory tree. Is there some API I can use to see a list these available but not active namespaces? I’m not aware of one. I'm guessing that looking at what's on the class path doesn't necessarily tell me what namespaces might be USE-able via (use 'x). Walking the classpath including the contents of jar files would be a way to construct such a list of USE-able (or REQUIRE-able) namespaces. It would involve traversing the directory structure under each entry in the classpath and reading at least the first ns form in each candidate file (or jar entry). —Steve -- -- 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 unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- With best wishes,Alex Ott http://alexott.net/ Twitter: alexott_en (English), alexott (Russian) Skype: alex.ott -- -- 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 a topic in the Google Groups Clojure group. To unsubscribe from this topic, visit https://groups.google.com/d/topic/clojure/mu25hM3Cw4w/unsubscribe. To unsubscribe from this group and all its topics, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- -- 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 unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: Namespaces in waiting
I just stumbled across this, which looks very much like it may be what I wanted: clojure.core/loaded-libs http://clojure.github.io/clojure/clojure.core-api.html#clojure.core/loaded-libs E.g. $ lein repl user= (loaded-libs) bultitude.core cemerick.pomegranate cemerick.pomegranate.aether classlojure.core clj-stacktrace.core clj-stacktrace.repl clj-stacktrace.utils clojure.core clojure.core.protocols clojure.instant ... clojure.zip complete.core dynapath.defaults dynapath.dynamic-classpath dynapath.util flatland.useful.fn flatland.useful.seq flatland.useful.utils jdt.cl jdt.core jdt.java jdt.shell leiningen.core.classpath leiningen.core.eval leiningen.core.main leiningen.core.project leiningen.core.ssl leiningen.core.user leiningen.core.utils leiningen.repl leiningen.trampoline me.raynes.conch me.raynes.conch.low-level net.cgrand.parsley net.cgrand.parsley.fold net.cgrand.parsley.grammar net.cgrand.parsley.lrplus net.cgrand.parsley.stack net.cgrand.parsley.tree ... and so on -- -- 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 unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: Namespaces in waiting
On Jan 1, 2014, at 3:26 PM, Dave Tenny dave.te...@gmail.com wrote: When I use 'lein repl' in some project context and get to the REPL prompt, there's an available but as yet not ... present ... namespace, i.e. (all-ns) won't list the namespace(s) created in the lein project directory tree. Is there some API I can use to see a list these available but not active namespaces? I’m not aware of one. I'm guessing that looking at what's on the class path doesn't necessarily tell me what namespaces might be USE-able via (use 'x). Walking the classpath including the contents of jar files would be a way to construct such a list of USE-able (or REQUIRE-able) namespaces. It would involve traversing the directory structure under each entry in the classpath and reading at least the first ns form in each candidate file (or jar entry). —Steve -- -- 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 unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Namespaces in waiting
When I use 'lein repl' in some project context and get to the REPL prompt, there's an available but as yet not ... present ... namespace, i.e. (all-ns) won't list the namespace(s) created in the lein project directory tree. Is there some API I can use to see a list these available but not active namespaces? I'm guessing that looking at what's on the class path doesn't necessarily tell me what namespaces might be USE-able via (use 'x). -- -- 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 unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.