sendman

CLI tool for sending files to a local/remote location


Sendman is a CLI tool for sending files to a local/remote location.

This is handy when you want to use a configuration file to define the local/remote server host, port, username, password, local path, and remote path of the files you want to send via FTP, SCP, or rsync. No more retyping lengthy commands one by one.

npm install -g sendman

Create a sample .sendman.json configuration file:

sendman init

Configuration file contains:

{
  "protocol": "scp",
  "host": "somehost",
  "port": 22,
  "username": "someusername",
  "password": "somepassword",
  "local": "/path/to/local/dir",
  "remote": "/path/to/remote/dir"
}

Send the files located at local path to remote location:

sendman send

It's possible to include sub-configuration file.

.sendman.json contains:

{
  "protocol": "ftp",
  "host": "somehost",
  "port": 21,
  "local": "/path/to/local/dir",
  "remote": "/path/to/remote/dir",
  "parallel": 10,
  "include": "/path/to/.secretSendman.json"
}

.secretSendman.json contains:

{
  "username": "someusername",
  "password": "somepassword"
}

Alternatively, you can use rsync to send files to a remote host.

{
  "protocol": "rsync",
  "host": "somehost",
  "local": "/path/to/local/dir",
  "remote": "/path/to/remote/dir"
}

rsync can also be used to send files between local paths.

{
  "protocol": "rsync",
  "source": "/path/to/local/dir1",
  "destination": "/path/to/local/dir2"
}

Developer's Guide

Build reports: