Use ? for bool values

This commit is contained in:
Tom Willemsen 2012-09-26 00:22:32 +02:00
parent 0b9682ea2b
commit b585ff11d0

View file

@ -189,16 +189,16 @@ to the tracked files. Utracked files will not register."
(define (main args)
"Parse the command line options and run the appropriate functions."
(let* ((options (getopt-long args option-spec))
(help-wanted (option-ref options 'help #f))
(version-wanted (option-ref options 'version #f))
(registration-needed (option-ref options 'register #f))
(removal (option-ref options 'remove #f))
(list (option-ref options 'repositories #f))
(purge? (option-ref options 'purge #f)))
(cond (version-wanted (version))
(help-wanted (help))
(registration-needed => register-repository)
(removal => remove-repository)
(list (list-repository-locations))
(purge? (purge))
(#t (list-repositories)))))
(help-wanted? (option-ref options 'help #f))
(version-wanted? (option-ref options 'version #f))
(registration-needed? (option-ref options 'register #f))
(removal? (option-ref options 'remove #f))
(list? (option-ref options 'repositories #f))
(purge? (option-ref options 'purge #f)))
(cond (version-wanted? (version))
(help-wanted? (help))
(registration-needed? => register-repository)
(removal? => remove-repository)
(list? (list-repository-locations))
(purge? (purge))
(#t (list-repositories)))))