Removed too-many-args error message in place of just 'incorrect usage' error
parent
42591a97fc
commit
dbd80a0b2c
15
src/rodo.rkt
15
src/rodo.rkt
|
@ -27,12 +27,6 @@
|
||||||
;; ------------------------------------------------
|
;; ------------------------------------------------
|
||||||
(define messages
|
(define messages
|
||||||
(hash
|
(hash
|
||||||
'error-too-many-arguments
|
|
||||||
(format (string-append "Error: Too many arguments." newline
|
|
||||||
"Try running '~a ~a' for more information.")
|
|
||||||
program-name
|
|
||||||
help-command-1)
|
|
||||||
|
|
||||||
'error-incorrect-usage
|
'error-incorrect-usage
|
||||||
(format (string-append "Error: Incorrect usage." newline
|
(format (string-append "Error: Incorrect usage." newline
|
||||||
"Try running '~a ~a' for more information.")
|
"Try running '~a ~a' for more information.")
|
||||||
|
@ -283,13 +277,8 @@
|
||||||
[(vector (== init-command)) (init)]
|
[(vector (== init-command)) (init)]
|
||||||
[(vector (== add-command) a) (add a)]
|
[(vector (== add-command) a) (add a)]
|
||||||
[(vector (== rm-command) a) (rm a)]
|
[(vector (== rm-command) a) (rm a)]
|
||||||
[(vector _ _ _ ...)
|
[(vector _ ...) (displayln-messages-ref 'error-incorrect-usage)]
|
||||||
(displayln-messages-ref 'error-too-many-arguments)]
|
[_ (ls)]))
|
||||||
[(vector _ _)
|
|
||||||
(displayln-messages-ref 'error-incorrect-usage)]
|
|
||||||
[(vector _)
|
|
||||||
(displayln-messages-ref 'error-incorrect-usage)]
|
|
||||||
[_ (ls)]))
|
|
||||||
|
|
||||||
(define (main vectorof-args)
|
(define (main vectorof-args)
|
||||||
(process-args vectorof-args))
|
(process-args vectorof-args))
|
||||||
|
|
Loading…
Reference in New Issue