rename "change" to "passwd"

This commit is contained in:
Florian Weingarten 2015-04-25 02:42:52 -04:00
parent 8be6dc0265
commit dead2b7e93
2 changed files with 4 additions and 4 deletions

View file

@ -114,7 +114,7 @@ func change_password(s restic.Server) error {
} }
func (cmd CmdKey) Usage() string { func (cmd CmdKey) Usage() string {
return "[list|add|rm|change] [ID]" return "[list|add|rm|passwd] [ID]"
} }
func (cmd CmdKey) Execute(args []string) error { func (cmd CmdKey) Execute(args []string) error {
@ -139,7 +139,7 @@ func (cmd CmdKey) Execute(args []string) error {
} }
return delete_key(s, id) return delete_key(s, id)
case "change": case "passwd":
return change_password(s) return change_password(s)
} }

View file

@ -15,9 +15,9 @@ unset RESTIC_PASSWORD
RESTIC_PASSWORD=foo run restic init RESTIC_PASSWORD=foo run restic init
RESTIC_PASSWORD=foo run restic key list RESTIC_PASSWORD=foo run restic key list
RESTIC_PASSWORD=foo RESTIC_NEWPASSWORD=foobar run restic key change RESTIC_PASSWORD=foo RESTIC_NEWPASSWORD=foobar run restic key passwd
RESTIC_PASSWORD=foobar run restic key list RESTIC_PASSWORD=foobar run restic key list
RESTIC_PASSWORD=foobar RESTIC_NEWPASSWORD=foo run restic key change RESTIC_PASSWORD=foobar RESTIC_NEWPASSWORD=foo run restic key passwd
OLD_PWD=foo OLD_PWD=foo
for i in {1..3}; do for i in {1..3}; do