Revert to digits for writing a post, and use

correct "pr-str" to write edn data.
This commit is contained in:
Charlotte Allen 2020-02-03 12:53:54 -08:00
parent 4f3cfe4728
commit be0aeeb80d
1 changed files with 2 additions and 2 deletions

View File

@ -25,9 +25,9 @@
(defn write-post [post dt-path]
(let [path (pathmap-to-path dt-path)
increment (inc (count-posts-in-date dt-path))
final-path (format "%s/%s/%d/%s" base-posts-path path increment post-filename)]
final-path (format "%d/%d/%d/%d" base-posts-path path increment post-filename)]
(clojure.java.io/make-parents final-path)
(spit final-path post)))
(spit final-path (pr-str post))))
(defn assoc-author [post]
(let [filename (get-in post [:properties :author])