(append writer value)
Append a single form to a writer, followed by a newline.
Append a single form to a writer, followed by a newline.
(reader-seq reader)
Given a PushBackReader, return a lazy seq of forms.
Given a PushBackReader, return a lazy seq of forms.
(slurp f)
Read in an ednl file. Returns a lazy sequence of EDN values.
Read in an ednl file. Returns a lazy sequence of EDN values.
(spit f contents & [{:keys [append?] :or {append? false} :as options}])
Write out a sequence of EDN values to a file.
Options:
:append?
append to the file, instead of overwriting it. Defaults to false
.Write out a sequence of EDN values to a file. Options: - `:append?` append to the file, instead of overwriting it. Defaults to `false`.
(with-append [append-binding file] & body)
Open a file in append mode, and add forms to it, using the append function which gets bound in the binding form.
The file is closed at the end of the scope.
(with-append [append "outfile.ednl"] (append [1 2 3]) (append [:x :y :z]))
Open a file in append mode, and add forms to it, using the append function which gets bound in the binding form. The file is closed at the end of the scope. (with-append [append "outfile.ednl"] (append [1 2 3]) (append [:x :y :z]))
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close