sendman

CLI tool for sending files to a remote server

npm install sendman
7 downloads in the last month

Avatar

Build Status Dependencies Status Coverage Status Published Version
npm Badge

Sendman

Sendman is a CLI tool for sending files to a remote server.

This is handy when you want to use a configuration file to define the remote server host, port, username, password, local path, and remote path of the files you want to send via FTP or SCP.

Installation

npm install -g sendman

Usage

Create a sample .sendman.json configuration file:

sendman init

Configuration file contains:

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

Send the files at configured local path:

sendman send

If .sendman.json is stored in a public SCM, it's better to store username, and password in a sub-configuration file.

.sendman.json contains:

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

.secretSendman.json contains:

{
  "username": "someusername",
  "password": "somepassword"
}
npm loves you