Move more stuff into configuration module.
This commit is contained in:
parent
49a638fa76
commit
bc0420bbc0
4 changed files with 22 additions and 18 deletions
|
@ -29,17 +29,33 @@
|
|||
configuration
|
||||
(
|
||||
*current-month*
|
||||
*member-file-context*
|
||||
*member-file-check-syntax*
|
||||
*member-default-joined*
|
||||
)
|
||||
|
||||
(import scheme
|
||||
(chicken base)
|
||||
(chicken time)
|
||||
(chicken time posix))
|
||||
(chicken time posix)
|
||||
month)
|
||||
|
||||
;; Current month - if changed, we get the actual state for given month.
|
||||
(define *current-month*
|
||||
(make-parameter
|
||||
(let ((d (seconds->local-time (current-seconds))))
|
||||
(list (+ 1900 (vector-ref d 5))
|
||||
(vector-ref d 4)))))
|
||||
|
||||
;; Configuration of error reporting
|
||||
(define *member-file-context* (make-parameter 3))
|
||||
|
||||
;; Tolerance to formal errors (invalid key or key without value):
|
||||
;; 'error - show source and exits with error
|
||||
;; 'warning - show source and error, continue
|
||||
;; 'quiet - ignore
|
||||
(define *member-file-check-syntax* (make-parameter 'error))
|
||||
|
||||
(define *member-default-joined* (make-parameter (make-month 2015 1)))
|
||||
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue