snow-fort-guix-channel/get-package-urls.r7rs-scm

16 lines
448 B
Plaintext

(import (scheme base)
(scheme read)
(scheme write)
(scheme file))
(if (not (file-exists? "repo.scm")) (error "No repo.scm found"))
(define repository (with-input-from-file "repo.scm" (lambda () (read))))
(define base-url "https://snow-fort.org")
(for-each
(lambda (item)
(when (equal? (car item) 'package)
(display (string-append base-url (cadr (assoc 'url (cdr item)))))
(newline)))
(cdr repository))