 
 
 ;; TODO: protocol maybe?
-(defn header->vec
-  "Takes array of CommentFields and translates to a proper Clojure vector"
-  [hs]
-  (for [^CommentField h hs]
-    [(-> h .name s/lower-case keyword) (.value h)]))
+;; unused, but might be needed later
+#_(defn header->vec
+    "Takes array of CommentFields and translates to a proper Clojure vector"
+    [hs]
+    (for [^CommentField h hs]
+      [(-> h .name s/lower-case keyword) (.value h)]))
 
 
 (defn album-mover
+  "Returns a CommentUpdater for use with JVorbisComment,
+   for updating comments in place,
+   which moves any ALBUM tags to ARTIST, removing any
+   ARTIST tags which might have been there.
+   Necessary because liquidsoap is broken and won't save
+   anything but artist in filename, and we've cleaned the artist
+   to make it a legal unix filename, so the real show name with
+   unescaped characters is stashed in ALBUM instead, and must be
+   recovered here."
   []
   (reify CommentUpdater
     (updateComments [this comments]



(defn format-show-save
  [path name date]
  (format "%s/%s-%s.ogg"  path date name))


(defn gen-command-line
  "Takes a file glob, returns the string command to process it"
  [cmd-path path {:keys [name date filenames]}]
  (let [cmd (format "cat %s | %s > %s"
                    (umisc/inter-str " " filenames)




(defn date-time-sort-partition
  "Takes a seq of filemaps.
   Sorts and groups them by DATE, not datetime,
