Skip to content

Instantly share code, notes, and snippets.

@dauuricus
Last active October 23, 2021 07:27
Show Gist options
  • Save dauuricus/1ca70c1abb025e10215a78b64f911f08 to your computer and use it in GitHub Desktop.
Save dauuricus/1ca70c1abb025e10215a78b64f911f08 to your computer and use it in GitHub Desktop.
(ql:quickload "drakma")
(defun x (y)
(dotimes (n y)
(setq res
(drakma:http-request "https://mangabank.org/watch/?tour=/vol/"))
(setq title_tag (ppcre:scan-to-strings "(?<=title\\>).*?(?=\\<)" res))
(if (setq author2 (ppcre:scan-to-strings "(?<=\\[).*?(?=\\])" title_tag))
(setq author author2)
(setq author "?"))
(if (setq title2 (ppcre:scan-to-strings "(?<=\\]).*?(?=\\s\\&)" title_tag))
(setq title title2)
(setq title (ppcre:scan-to-strings "^.*?(?=\\s\\&)" title_tag)))
(print (format t "~%~d ~A ~A" (+ 1 n) author title)))
)
@dauuricus
Copy link
Author

First function

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment