1. In its simplest form, EDN is just clojure data literals. So for simple
cases like configuration, just use a map:
{ :database-uri "some-uri"
:another-param "some value"
:debug-mode true }
2. You can use clojure.java.io/resource to access resources, but for config
files you usually don't want them as resources, since those will be embedded in
the jar/war file when you deploy, making it difficult to configure for
different deployment environments.
I have some generic code for loading config files that I use in most projects
now. I originally lifted it from some open-source project at one point (can't
remember which, or I would give credit). I'll create a gist and post the link
in a bit.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
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 [email protected].
For more options, visit https://groups.google.com/d/optout.