You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
632 B
23 lines
632 B
(in-package #:lolicore)
|
|
|
|
(defmacro str (&rest strs)
|
|
"Concatenate a list of strings `strs' to one string."
|
|
`(concatenate 'string ,@strs))
|
|
|
|
(defun add-data (keyword key json)
|
|
(cons keyword (jsown:val json key)))
|
|
|
|
(defmacro add-booru (&rest args)
|
|
`(push (make-instance 'booru ,@args) *boorus*))
|
|
|
|
(defun list-boorus ()
|
|
"List all of the exported boorus"
|
|
(loop for booru in *boorus* collect (name booru)))
|
|
|
|
(defun get-booru (name)
|
|
"Get a specific `booru' from `*boorus*' by name"
|
|
(loop for booru in *boorus*
|
|
do (when (eql name (:name booru))
|
|
(return booru))
|
|
finally (error "No such booru")))
|