cli/secrets: show hint in --help on how to retrieve a key
All checks were successful
checks / check-links (pull_request) Successful in 14s
checks / checks-impure (pull_request) Successful in 1m51s
checks / checks (pull_request) Successful in 4m10s

This commit is contained in:
DavHau 2024-04-02 14:31:20 +07:00
parent 3428b76dcb
commit 16ae51105e

View File

@ -116,7 +116,9 @@ def register_users_parser(parser: argparse.ArgumentParser) -> None:
add_parser.add_argument("user", help="the name of the user", type=user_name_type)
add_parser.add_argument(
"key",
help="public key or private key of the user",
help="public key or private key of the user."
"Execute 'clan secrets key --help' on how to retrieve a key."
"To fetch an age key from an SSH host key: ssh-keyscan <domain_name> | nix shell nixpkgs#ssh-to-age -c ssh-to-age",
type=public_or_private_age_key_type,
)
add_parser.set_defaults(func=add_command)