Commit a4a3bda0 authored by Michael Raskin's avatar Michael Raskin

Syncing from Monotone at 20190408-024649. Last commit message was Typo fix

parent b10bff32
(use-package :thoughtful-theridion)
(print
(page-walk (x "http://planet.lisp.org/2019/3.html" :recur recur)
(let prev "tr:first-child > td > a"
("href" x))
(page-walk-each
(page-walk (x x :fetch nil :keep-brancher t)
(page-walk-maybe-each-of "li > a")
("href" x)
(if (cl-ppcre:scan "/201[0-8]/" x)
(page-walk-each) x))
(recur prev))))
(page-walk (x "https://planet.lisp.org/")
"div#content > p > a"
("href" x)
(page-walk (x x :recur recur)
(let prev "tr:first-child > td > a"
("href" x))
(page-walk-each
(page-walk (x x :fetch nil :keep-brancher t)
(page-walk-maybe-each-of "li > a")
("href" x)
(if (cl-ppcre:scan "/201[0-8]/" x)
(page-walk-each) x))
(recur prev)))))
......@@ -255,4 +255,5 @@
(defun html-inner-text (element)
(html-element-to-text
element (make-instance 'html-textifier-protocol)))
(make-instance 'html-textifier-protocol)
element))
......@@ -76,16 +76,18 @@
(labels ((,descend (,result-var)
(if (typep ,result-var
'page-walker-brancher)
(page-walk-each-of
(loop for ,var in
(page-walker-branches
,result-var)
for ,rest-result-var :=
(,descend ,var)
until
(page-walker-terminator-p
(if (null (page-walker-branches ,result-var))
,result-var
(page-walk-each-of
(loop for ,var in
(page-walker-branches
,result-var)
for ,rest-result-var :=
(,descend ,var)
until
(page-walker-terminator-p
,rest-result-var)
collect ,rest-result-var))
collect ,rest-result-var)))
(let ((,result-var ,result-var)
(,var ,var))
,main-form))))
......@@ -186,16 +188,19 @@
(labels ((,descend (,result-var)
(if (typep ,result-var
'page-walker-brancher)
(page-walk-each-of
(loop for ,var in
(page-walker-branches
,result-var)
for ,rest-result-var :=
(,descend ,var)
until
(page-walker-terminator-p
(if (null (page-walker-branches
,result-var))
,result-var
(page-walk-each-of
(loop for ,var in
(page-walker-branches
,result-var)
for ,rest-result-var :=
(,descend ,var)
until
(page-walker-terminator-p
,rest-result-var)
collect ,rest-result-var))
collect ,rest-result-var)))
(let ((,var ,result-var))
,rest-form))))
(,descend ,result-var))))))))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment