Do you have to upload or download files, execute commands remotely?
sshi scp local.txt @remote:/path/to
sshi @remote du -h /tmp
sshi globally or within your project:
$ npm i -g sshi # or `npm i sshi --save-dev`
How it works?
It stores your input in the
~/.sshiconf file, each line is a record with name/endpoint separated by white-space, e.g.
admin email@example.com -p 22022 -L 1025:localhost:1025my-site firstname.lastname@example.org
sshi @admin to get connected, any additional arguments are sent as command through the SSH connection.
- To add new endpoints
sshi save name user@host [...]
- To remove added endpoints
sshi del name
- To list all registered endpoints
When the first argument is not an
@endpoint placeholder, then command substitution is performed and executed, e.g.
$ sshi echo Your connection is: @my-site# Your connection is: email@example.com
Additional arguments after
user@hostare always saved, and also given to expanded commands.