commit 8029252

chld  ·  2026-09-18 17:03:27 +0000 UTC
parent a17b989
fix dull.conf.sh reading
1 files changed,  +5, -3
+5, -3
 1@@ -2,14 +2,15 @@
 2   (let rc
 3       (
 4        (c (call-with-input-file "/etc/dull.conf.sh" (lambda (f)
 5-						      (string-split (read-string f) #\newline)))
 6+						      (string-split (string-trim (read-string f)) #\newline)))
 7 	  )
 8        (n 0)
 9        )
10 
11     (unless (= n (length c))
12-      (let ((cl (string-split (list-ref c n) #\=)))
13-	(setenv (car cl) (cadr cl)))
14+      (unless (string-null? (list-ref c n))
15+	(let ((cl (string-split (list-ref c n) #\=)))
16+	  (setenv (car cl) (cadr cl))))
17       (rc c (+ n 1))
18       ))
19   )
20@@ -18,3 +19,4 @@
21 (define DULL_DIR "/var/tmp/dtr")
22 (define DULL_DB "/var/lib/dull")
23 (define DULL_PATH (or (getenv "DULL_PATH") "/ports-dull"))
24+(define (pkg-db pkg) (format #f "~a/~a" DULL_DB pkg))