Guile Freenet
 
(drak)
2016-02-10: run parse-trust-values

run parse-trust-values

diff --git a/parse-crawled.scm b/parse-crawled.scm
--- a/parse-crawled.scm
+++ b/parse-crawled.scm
@@ -23,10 +23,23 @@
              (ice-9 ftw))
 
 
+(define (non-breaking-sxml-reader xml-port)
+  (catch #t
+         (lambda () (xml->sxml xml-port))
+         (lambda (key . args) (format #t "~A: ~A" key args)(newline) '())))
+
+
+(define (parse-trust-values filename)
+  (let* ((port (open-input-file filename))
+         (sxml (non-breaking-sxml-reader port))
+         (closed (close-port port)))
+    #f))
+    
+
 (define (main args)
   (let ((dir (if (null? (cdr args))
                  "."
                  (car (cdr args)))))
-    (let ((select? (lambda (x) (or (equal? x ".") (string-prefix? "USK@" x)))))
-      (write (length (scandir dir select?)))
+    (let ((select? (lambda (x) (or (equal? x ".") (string-prefix? "USK@--PQYgLrwxB~4Q~vok8EVMCGoPzxSsVem6TwsN9CBKE,UEcmWOEG24NhwoMlP8IkhySUUyRkPwZnIsNoP2nZy4U,AQACAAE-WebOfTrust-0" x)))))
+      (write (map parse-trust-values (cdr (scandir dir select?))))
       (newline))))