630a06bb32d85aff87731ff417b031b7ad9fb779
2 (in-package :lineal.webui
)
4 ;V Compile given ParenScript file.V
5 (defun compile-ps (ps-path js-path
)
6 (when (and (probe-file js-path
)
7 (< (file-write-date ps-path
)
8 (file-write-date js-path
)))
9 (return-from compile-ps
))
10 (format t
"Generating: ~A~%" (namestring js-path
))
11 (with-open-file (ps-strm ps-path
)
12 (with-open-file (js-strm js-path
:direction
:output
13 :if-exists
:supersede
)
14 (loop :for lis
= (read ps-strm nil nil
)
16 :do
(princ (eval (list 'ps lis
)) js-strm
)
17 :do
(terpri js-strm
)))))
19 (defun recompile-ps ()
20 (ensure-directories-exist
22 :directory
'(:relative
"http_root" "jsfiles")))
27 :directory
'(:relative
"src" "webui" "psfiles")
28 :name name
:type
"lisp")
30 :directory
'(:relative
"http_root" "jsfiles")
31 :name name
:type
"js")))