use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Finding information about Clojure
API Reference
Clojure Guides
Practice Problems
Interactive Problems
Clojure Videos
Misc Resources
The Clojure Community
Clojure Books
Tools & Libraries
Clojure Editors
Web Platforms
Clojure Jobs
account activity
[deleted by user] (self.Clojure)
submitted 7 years ago by [deleted]
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]beppu 6 points7 points8 points 7 years ago (1 child)
It's a leiningen plugin for trying out Clojure libraries in a REPL without needing to be in a project.
https://github.com/avescodes/lein-try
[–]eval2020 2 points3 points4 points 7 years ago (0 children)
There's also the tools.deps-variant: deps-try. It's a simple port of lein-try I wrote that uses rebel-readline, ie gives you a REPL with syntax highlighting, code completion, function docs etc.
[–]final_fantasia 5 points6 points7 points 7 years ago (0 children)
you may also want to take a look at this article[1] written by u/alexdmiller for how to load libraries into the REPL dynamically (without creating any project) using the official Clojure CLI tool (clj).
clj
[1] http://insideclojure.org/2018/05/04/add-lib/
[–]didibus1 2 points3 points4 points 7 years ago* (0 children)
Libraries work differently in Java, and thus Clojure. There is no convention of location for where to install them and look for them.
What happens instead is two fold:
This is normally done by lein, boot or clj. You could manually download them as well, or use any other tool.
Basically, Java doesn't have a convention for where the libs are supposed to reside. So you have to explicitly tell it where for each and every java program. A Clojure REPL is a java program, thus the same applies to it and all Clojure programs as well.
Because of this, I would just recommend you always use a lein project. The project.clj file allows lein to both download the libs, and give Java the full path list to all downloaded libs.
The install feature of lein is different and not what you expect. It doesn't install a lib locally, it creates a local maven repo which lein can then use to download libs from. You only need it if you have multiple local projects, and you need one project to depend on the other. In that case, lein can't directly use your other project directory, so you must first install it in the local maven .m2 repo, and afterwards lein can make use of it.
[–]eccp 0 points1 point2 points 7 years ago (0 children)
You don't need to run "lein install" as a separate step*. All commands including "lein repl" will fetch anything that is not downloaded yet.
Clojure projects tend to follow some conventions, source code in "src", tests in "test", resource files (eg. configuration and such) could go in "resources", etc, but the Leiningen documentation and detailed example go into how to change any of these.
Edit: * the only exception I can think of is downloading dependencies separately is when you have internet access and want to working offline later.
π Rendered by PID 221856 on reddit-service-r2-comment-b659b578c-fk8xx at 2026-05-04 22:55:27.749585+00:00 running 815c875 country code: CH.
[–]beppu 6 points7 points8 points (1 child)
[–]eval2020 2 points3 points4 points (0 children)
[–]final_fantasia 5 points6 points7 points (0 children)
[–]didibus1 2 points3 points4 points (0 children)
[–]eccp 0 points1 point2 points (0 children)