          :default                        [s]))
       flatten))
 
-(defn generate-spec
+(defn ^:private generate-spec
   [raw-spec]
   (let [[switches raw-spec] (split-with #(and (string? %) (opt? %)) raw-spec)
         [docs raw-spec]     (split-with string? raw-spec)

           options)))

(defn cli
  [args & specs]
  (let [specs (map generate-spec specs)]
    (let [[options extra-args] (apply-specs specs args)

                     (contains? switches arg))))
       first))

(defn ^:private default-values-for
  [specs]
  (into {} (for [s specs] [(s :name) (s :default)])))

(defn ^:private apply-specs
  [specs args]
  (loop [options    (default-values-for specs)
         extra-args []
