git/cl-yag/commit/f74fe5f96516ad07e66b118d01fee022baa43d56.html (1989 bytes)
1 <!DOCTYPE html> 2 <html lang="en"><head><meta charset="UTF-8" /> 3 <meta name="viewport" content="width=device-width, initial-scale=1" /> 4 <title>cl-yag f74fe5f9 - Recently Written</title> 5 <link rel="stylesheet" href="../../stagit.css" /> 6 </head><body> 7 <div id="top"><a href="../../../index.html">Recently Written</a> · <a href="../../index.html">git</a></div> 8 <h1>cl-yag</h1><span class="desc">Mirror and rewrite of Solène Rapenne's cl-yag SSG of renown</span><p class="url">git clone https://github.com/equwal/cl-yag</p><p><a href="../../cl-yag/index.html">Log</a> | <a href="../../cl-yag/files.html">Files</a> | <a href="../../cl-yag/refs.html">Refs</a></p><hr/> 9 <div id="content"> 10 <pre>commit f74fe5f96516ad07e66b118d01fee022baa43d56 11 Spenser Truex <truex@equwal.com> 12 2025-09-01 17:14:10 -0400 13 14 Bugfix: ensure files and directories jive 15 16 </pre><pre> generators-util.lisp | 3 ++- 17 1 file changed, 2 insertions(+), 1 deletion(-) 18 </pre><pre>diff --git a/generators-util.lisp b/generators-util.lisp 19 index c76559d..0de1b4a 100644 20 --- a/generators-util.lisp 21 +++ b/generators-util.lisp 22 <span class="h">@@ -30,7 +30,7 @@</span> 23 (defun load-file(path) 24 "Load a file as a string. We escape ~ to avoid failures with format." 25 (if (probe-file path) 26 <span class="d">- (handler-case (with-open-file (stream path :if-exists :supersede :if-does-not-exist :create)</span> 27 <span class="a">+ (handler-case (with-open-file (stream path :direction :input)</span> 28 (let ((contents (make-string (file-length stream)))) 29 (read-sequence contents stream) 30 contents)) 31 <span class="h">@@ -40,6 +40,7 @@</span> 32 33 (defun save-file(path data) 34 "Save a string to a file." 35 <span class="a">+ (ensure-directories-exist path)</span> 36 (with-open-file (stream path :direction :output :if-exists :supersede :if-does-not-exist :create) 37 (write-sequence data stream))) 38 </pre> 39 </div></body></html>