summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrsiddharth <s@ricketyspace.net>2019-06-18 19:42:10 -0400
committerrsiddharth <s@ricketyspace.net>2019-06-18 19:42:10 -0400
commitd6ada43cacdd28cd0eecfa1bdeb67941e05738ba (patch)
tree765ce1d89c68695f19a24dc695cd9dee37c0c073
parent3486c51ebe5e3c2c2855a27d0094fdc3cf20767d (diff)
hn/g: Add athings:data-dir.
* hn/g (athings:data-dir): New function.
-rwxr-xr-xhn/g5
1 files changed, 5 insertions, 0 deletions
diff --git a/hn/g b/hn/g
index cd201b8..57d9fa3 100755
--- a/hn/g
+++ b/hn/g
@@ -53,4 +53,9 @@
(athings:latest (hash-set h (string->symbol id) link)
(cdr athings:sxml))))))
+(define (athings:data-dir)
+ (let ((dir (build-path (find-system-path 'orig-dir) "data")))
+ (unless (directory-exists? dir) (make-directory dir))
+ dir))
+