       (perun/set-meta fileset updated-files)
       (commit fileset tmp))))
 
+(defn meta-by-ext
+  [fileset file-exts]
+  (->> fileset
+       boot/user-files
+       (boot/by-ext file-exts)
+       (keep perun/+meta-key+)))
+
 (defn content-pre-wrap
   "Wrapper for input parsing tasks. Calls `parse-form` on new or changed
   files with extensions in `file-exts`, adds `tracer` to `:io.perun/trace`

                               boot/user-files
                               (boot/by-ext file-exts)
                               add-filedata)
            input-metadata (->>
                            (if pod
                              (pod/with-call-in @pod ~(parse-form changed-files))
                              (eval (parse-form changed-files)))
                            (trace tracer))
            prev-fs-files (if @prev-fs
                            (->> @prev-fs
                                 boot/user-files
                                 (boot/by-ext file-exts)
                                 set)
                            #{})
            unchanged-metadata (->> changed-files
                                    set
                                    (set/difference prev-fs-files)
                                    (filter #(boot/tmp-get fileset %))
                                    (keep perun/+meta-key+))
            output-metadata (doall
                             (for [{:keys [path parsed filename] :as entry*} (concat input-metadata
                                                                                     unchanged-metadata)]
                               (let [page-filepath (string/replace path #"(?i).[a-z]+$" ".html")
                                     entry (-> entry*
                                               (assoc :has-content true)
                                               (assoc :original-path path)
                                               (assoc :path page-filepath)
                                               (assoc :filename (string/replace filename
                                                                                #"(?i).[a-z]+$" ".html"))
                                               (dissoc :parsed :extension :file-type
                                                       :full-path :mime-type :original))]
                                 (perun/create-file tmp page-filepath parsed)
                                 entry)))
            input-metadata* (map #(-> %
                                      (dissoc :include-rss)
                                      (dissoc :include-atom))
                                 input-metadata)
            final-metadata (perun/merge-meta* (perun/get-meta @prev-fs)
                                              (concat input-metadata* output-metadata))
            new-fs (-> fileset
                       (commit tmp)
                       (perun/set-meta final-metadata))]
        (reset! prev-fs new-fs)
        new-fs))))


            [boot.pod :as pod]
            [boot.util :as u]
            [clojure.java.io :as io]
            [clojure.string :as string]
            [clojure.edn :as edn]
            [io.perun.core :as perun]))
