Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ var scp = require('scp');

var options = {
file: 'dump.sql'
user: 'username',
host: 'myServer',
path: '~'
}
Expand All @@ -33,11 +34,12 @@ Send a file to a remote host (in your `~/.ssh/config`)

You must pass in `options`. A `cb` function is optional, and will be passed `err`, `stdout`, and `stderr`.

There are currently 3 options:
There are currently 4 options:

````javascript
scp.send({
file: './file.txt', // local file to send
user: 'username', // username to authenticate as on remote system
host: 'myServer', // remote host to copy to, set up in your ~/.ssh/config
path: '~' // remote path to save to (this would result in a ~/file.txt on myServer)
});
Expand All @@ -54,6 +56,7 @@ There are currently 3 options:
````javascript
scp.get({
file: '~/file.txt', // remote file to grab
user: 'username', // username to authenticate as on remote system
host: 'myServer', // remote host to transfer from, set up in your ~/.ssh/config
path: '~' // local path to save to (this would result in a ~/file.txt on the local machine)
});
Expand Down