49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
(if (<= n *verbosity*)
(apply print params)))
;; if a value is printable (i.e. string or number) return the value
;; else return an empty string
(define-inline (printable val)
(if (or (number? val)(string? val)) val ""))
;;======================================================================
;; System stuff
;;======================================================================
(define (get-df path)
(let* ((df-results (cmd-run->list (conc "df " path)))
|
>
>
>
>
>
>
>
>
|
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
|
(if (<= n *verbosity*)
(apply print params)))
;; if a value is printable (i.e. string or number) return the value
;; else return an empty string
(define-inline (printable val)
(if (or (number? val)(string? val)) val ""))
;; convert stuff to a number if possible
(define (any->number val)
(cond
((number? val) val)
((string? val) (string->number val))
((symbol? val) (any->number (symbol->string val)))
(else #f)))
;;======================================================================
;; System stuff
;;======================================================================
(define (get-df path)
(let* ((df-results (cmd-run->list (conc "df " path)))
|