taypo / redial

SSH Session Manager
GNU General Public License v3.0
201 stars 15 forks source link

Fix ssh-copy-id command, port then host #55

Closed LazyGatto closed 1 year ago

LazyGatto commented 1 year ago

Description

Fix ssh-copy-id command, port then host

Motivation and Context

In current version ssh-copy-id gives an error:

/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed: "/Users/username/.ssh/id_ed25519.pub"
/usr/bin/ssh-copy-id: ERROR: Too many arguments.  Expecting a target hostname, got:

Usage: /usr/bin/ssh-copy-id [-h|-?|-f|-n|-s] [-i [identity_file]] [-p port] [-F alternative ssh_config file] [[-o <ssh -o options>] ...] [user@]hostname
    -f: force mode -- copy keys without trying to check if they are already installed
    -n: dry run    -- no keys are actually copied
    -s: use sftp   -- use sftp instead of executing remote-commands. Can be useful if the remote only allows sftp
    -h|-?: print this help

Types of changes

Small change to change place of port in command