mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-07 15:36:20 -05:00
ui: Filter out internal commands from '--help'.
* guix/ui.scm (show-guix-help)[internal?]: New procedure. Use it to filter out internal commands reported by '--help'.
This commit is contained in:
parent
54ff0b7dd7
commit
59f734f351
1 changed files with 5 additions and 1 deletions
|
@ -558,13 +558,17 @@ (define (commands)
|
|||
(command-files)))
|
||||
|
||||
(define (show-guix-help)
|
||||
(define (internal? command)
|
||||
(member command '("substitute-binary" "authenticate")))
|
||||
|
||||
(format #t (_ "Usage: guix COMMAND ARGS...
|
||||
Run COMMAND with ARGS.\n"))
|
||||
(newline)
|
||||
(format #t (_ "COMMAND must be one of the sub-commands listed below:\n"))
|
||||
(newline)
|
||||
;; TODO: Display a synopsis of each command.
|
||||
(format #t "~{ ~a~%~}" (sort (commands) string<?))
|
||||
(format #t "~{ ~a~%~}" (sort (remove internal? (commands))
|
||||
string<?))
|
||||
(show-bug-report-information))
|
||||
|
||||
(define program-name
|
||||
|
|
Loading…
Reference in a new issue