- added a usage-screen and a system-type check
This commit is contained in:
parent
0b1163c4c3
commit
d403ceb52e
|
@ -321,9 +321,20 @@ Please choose a password with at least 2 character classes.")
|
|||
(else
|
||||
(lp pw))))))))
|
||||
|
||||
(define (display-usage)
|
||||
(display "Usage: passwd-wrapper.scm\n")
|
||||
(display "Change NIS, Kerberos IV and Kerberos V passwords at once.\n")
|
||||
(display "Written by David Frese.\n"))
|
||||
|
||||
(define (main args)
|
||||
(if (null? (cdr args))
|
||||
(case system-type
|
||||
((freebsd solaris)
|
||||
(let ((old-pw (ask/check-old-password))
|
||||
(new-pw (ask-new-password)))
|
||||
(if (change-all-passwords old-pw new-pw)
|
||||
(display "Password changed.\n")
|
||||
(display "Password could not be changed.\n"))))
|
||||
(else
|
||||
(raise-unsupported-machine)))
|
||||
(display-usage)))
|
||||
|
|
Loading…
Reference in New Issue