aboutsummaryrefslogtreecommitdiff
path: root/module/calp/entry-points/html.scm
diff options
context:
space:
mode:
Diffstat (limited to 'module/calp/entry-points/html.scm')
-rw-r--r--module/calp/entry-points/html.scm8
1 files changed, 7 insertions, 1 deletions
diff --git a/module/calp/entry-points/html.scm b/module/calp/entry-points/html.scm
index 7c4fe257..61489a85 100644
--- a/module/calp/entry-points/html.scm
+++ b/module/calp/entry-points/html.scm
@@ -75,7 +75,13 @@
;; TODO nicer way to resolve static
(let ((link (path-append output-directory "static")))
(unless (file-exists? link)
- (symlink (path-append (xdg-data-home) "calp" "www" "static") link)))))
+ (if (catch 'system-error
+ (lambda () (lstat link))
+ (lambda (err proc fmt fmt-args data)
+ #f))
+ (format #t "WARNING: broken symlink ~s → ~s~%"
+ link (readlink link))
+ (symlink (path-append (xdg-data-home) "calp" "www" "static") link))))))
(define (re-root-static tree)