File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed
Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change 22
33## Unreleased
44
5+ - Allow comments on ` json ` configs.
6+
57## 0.0.4
68
79- Add env support for MCPs
Original file line number Diff line number Diff line change 77 4. `initializatonOptions` sent in `initialize` request."
88 (:require
99 [cheshire.core :as json]
10+ [cheshire.factory :as json.factory]
1011 [clojure.core.memoize :as memoize]
1112 [clojure.java.io :as io]
1213 [clojure.string :as string]
3334
3435(defn ^:private safe-read-json-string [raw-string]
3536 (try
36- (json/parse-string raw-string true )
37+ (binding [json.factory/*json-factory* (json.factory/make-json-factory
38+ {:allow-comments true })]
39+ (json/parse-string raw-string true ))
3740 (catch Exception _
3841 nil )))
3942
4851 (io/file (get-property " user.home" ) " .config" ))
4952 config-file (io/file xdg-config-home " eca" " config.json" )]
5053 (when (.exists config-file)
51- (safe-read-json-string (slurp config-file)))))
54+ (safe-read-json-string (slurp config-file)))))
5255
5356(def ^:private config-from-global-file (memoize/ttl config-from-global-file* :ttl/threshold ttl-cache-config-ms))
5457
You can’t perform that action at this time.
0 commit comments