Fix web-static to work with new data structures.
This commit is contained in:
parent
993dce8750
commit
f3cf268a3c
2 changed files with 7 additions and 4 deletions
|
@ -220,7 +220,7 @@ members-payments.import.scm: $(MEMBERS-PAYMENTS-SOURCES)
|
|||
|
||||
WEB-STATIC-SOURCES=web-static.scm member-record.import.scm \
|
||||
utils.import.scm configuration.import.scm \
|
||||
members-payments.import.scm
|
||||
members-payments.import.scm members-base.import.scm
|
||||
|
||||
web-static.o: web-static.import.scm
|
||||
web-static.import.scm: $(WEB-STATIC-SOURCES)
|
||||
|
|
|
@ -39,10 +39,12 @@
|
|||
(chicken process-context)
|
||||
(chicken pathname)
|
||||
(chicken file)
|
||||
(chicken file posix)
|
||||
member-record
|
||||
utils
|
||||
configuration
|
||||
members-payments)
|
||||
members-payments
|
||||
members-base)
|
||||
|
||||
;; Generate all the files in specified (default current) directory.
|
||||
(define (gen-web-static-member mr . dirs)
|
||||
|
@ -79,11 +81,12 @@
|
|||
|
||||
;; Generates all member files in given directory
|
||||
(define (gen-web-static mb dir)
|
||||
(when (file-exists? dir)
|
||||
(when (and (file-exists? dir)
|
||||
(regular-file? dir))
|
||||
(error 'gen-web-static "Directory is a file:" dir))
|
||||
(when (not (directory-exists? dir))
|
||||
(create-directory dir))
|
||||
(let loop ((mb mb))
|
||||
(let loop ((mb (members-base-members mb)))
|
||||
(when (not (null? mb))
|
||||
(gen-web-static-member (car mb) dir)
|
||||
(loop (cdr mb)))))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue