summaryrefslogtreecommitdiff
path: root/tissue
diff options
context:
space:
mode:
authorArun Isaac2022-12-25 19:01:20 +0000
committerArun Isaac2022-12-25 23:33:05 +0000
commitef213c41ace0c60eeb96ae9fa4d6db4f234926c3 (patch)
treefcfefbbf36256bf563cdbe485d84c6b995df1ac1 /tissue
parent4e4c3eb23a65d661d0715988cd109da55d08e761 (diff)
downloadtissue-ef213c41ace0c60eeb96ae9fa4d6db4f234926c3.tar.gz
tissue-ef213c41ace0c60eeb96ae9fa4d6db4f234926c3.tar.lz
tissue-ef213c41ace0c60eeb96ae9fa4d6db4f234926c3.zip
web: static: Deprecate with-current-directory.
with-current-directory is the exact same as call-with-current-directory from (tissue utils). * tissue/web/static.scm (with-current-directory): Delete function. (build-website): Replace with-current-directory with call-with-current-directory.
Diffstat (limited to 'tissue')
-rw-r--r--tissue/web/static.scm12
1 files changed, 2 insertions, 10 deletions
diff --git a/tissue/web/static.scm b/tissue/web/static.scm
index ffe7c8a..fbef99e 100644
--- a/tissue/web/static.scm
+++ b/tissue/web/static.scm
@@ -121,14 +121,6 @@ stylesheet is included in the generated web pages."
(evaluate-ast-from-port in #:reader reader)
engine)))))
-(define (with-current-directory directory thunk)
- "Change current directory to DIRECTORY, execute THUNK and restore
-original current directory."
- (let ((previous-current-directory (getcwd)))
- (dynamic-wind (const #t)
- thunk
- (cut chdir previous-current-directory))))
-
(define* (build-website repository-top-level output-directory files
#:key (log-port (current-error-port)))
"Export git repository with REPOSITORY-TOP-LEVEL to OUTPUT-DIRECTORY
@@ -150,6 +142,6 @@ Log to LOG-PORT. When LOG-PORT is #f, do not log."
(make-directories (dirname output-file))
(call-with-output-file output-file
(lambda (port)
- (with-current-directory repository-top-level
- (cut (file-writer file) port))))))
+ (call-with-current-directory repository-top-level
+ (cut (file-writer file) port))))))
files))