(define hello
(command
- '((count (single-char #\c) (default 1) (help "Number of greetings."))
- (name (prompt "Your name") (help "The person to greet.")))
- (lambda (count name)
- "Simple program that greets NAME for a total of COUNT times."
- (let loop ((times count))
- (cond ((> times 0)
- (format #t "Hello ~a!~%" name)
- (loop (- times 1))))))))
+ #:option-spec '((count (single-char #\c) (default 1) (help "Number of greetings."))
+ (name (prompt "Your name") (help "The person to greet.")))
+ #:procedure (lambda (count name)
+ "Simple program that greets NAME for a total of COUNT times."
+ (let loop ((times count))
+ (cond ((> times 0)
+ (format #t "Hello ~a!~%" name)
+ (loop (- times 1))))))))
(hello (command-line))