       "create" (create options arguments)
       "data" (data options)
       "list" (list_ options)
+      "record-payment" (record-payment options arguments)
       (exit 1 (usage summary)))))

  (apply println (map pretty-print-invoice (filter (options-to-filter options)
                                                   (read-all-invoices)))))

(defn -main [& args]
  (let [{:keys [options arguments errors summary]} (parse-opts args cli-options)]
    ;; Handle help and error conditions

        "    Lists invoices."
        ""
        "  invadm data {-c CURRENCY, -r CLIENT, -f FILENAME}"
        "    Dump all the data in a JSON array."
        ""
        "  invadm record-payment [-a AMOUNT] [-p PAID_ON] ID"
        "    Record a payment of AMOUNT for invoice ID."]
       (string/join \newline)))

(defn error-msg [errors]
