Error when creating ssh keys Git Too many arguments Solution

Original link: https: //blog.csdn.net/qq_31165799/article/details/72832269

If problems: Too many arguments error when git create key.

运行命令ssh-keygen -t rsa -C “[email protected]”时报错:
    Too many arguments.
    usage: ssh-keygen [-q] [-b bits] [-t dsa | ecdsa | ed25519 | rsa | rsa1]
                      [-N new_passphrase] [-C comment] [-f output_keyfile]
           ssh-keygen -p [-P old_passphrase] [-N new_passphrase] [-f keyfile]
           ssh-keygen -i [-m key_format] [-f input_keyfile]
           ssh-keygen -e [-m key_format] [-f input_keyfile]
           ssh-keygen -y [-f input_keyfile]
           ssh-keygen -c [-P passphrase] [-C comment] [-f keyfile]
           ssh-keygen -l [-v] [-E fingerprint_hash] [-f input_keyfile]
           ssh-keygen -B [-f input_keyfile]
           ssh-keygen -D pkcs11
           ssh-keygen -F hostname [-f known_hosts_file] [-l]
           ssh-keygen -H [-f known_hosts_file]
           ssh-keygen -R hostname [-f known_hosts_file]
           ssh-keygen -r hostname [-f input_keyfile] [-g]
           ssh-keygen -G output_file [-v] [-b bits] [-M memory] [-S start_point]
           ssh-keygen -T output_file -f input_file [-v] [-a rounds] [-J num_lines]
                      [-j start_line] [-K checkpt] [-W generator]
           ssh-keygen -s ca_key -I certificate_identity [-h] [-n principals]
                      [-O option] [-V validity_interval] [-z serial_number] file ...
           ssh-keygen -L [-f input_keyfile]
           ssh-keygen -A
           -k-keygen -f krl_file SSH [-u] [-s ca_public] [version_number the -z]
                      File ...
           SSH-keygen File ... -Q -f krl_file

problem everywhere:

Wrong Dash Symbol "-" in arguments The; are Started with Options "-" (minus Sign, ASCII code 0x2D) Here Follows the Command at The Same, with correct characters:.

    $ SSH-keygen -t rsa -C "[email protected]"
    Generating public / Private Key pair rsa.

it obviously, because of "-" question, get a day is drunk, but fortunately the problem solved. I hope everyone can help!

Guess you like

Origin www.cnblogs.com/yinminbo/p/11810146.html