简体   繁体   中英

How can I load profiles.clj into CURSIVE REPL?

My profiles.clj file starts with:

{:dev
    {:env {:env-name

How do I load it in CURSIVE REPL in order for me to be able to use (:env-name env) in my code?

The content of profiles.clj is not available to your REPL session. But you can read the file yourself:

(ns mastering.stackoverflow
    (:require
        [clojure.tools.reader.edn :as edn]))

    (-> ".....path...../profiles.clj "
        (slurp)
        (edn/read-string)
        :dev
        :env)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM