cmd-sync-servers

Keep a local site folder and its servers in step from the command line, the way Dreamweaver's Synchronize does.

New here? The Quickstart gets you to a first sync in five steps, and the Cheatsheets keep every everyday command and key on one page.

Before a new site's first sync, read its preview: it lists every file that would move, and nothing moves until you confirm.

What it does

Install

It needs Node.js 22.14 or later, on Windows, macOS or Linux.

npm install --global @isocialpractice/cmd-sync-servers
sync-servers --version

Or run it from a clone; npm link puts the sync-servers command on your PATH:

git clone https://github.com/isocialPractice/cmd-sync-servers.git
cd cmd-sync-servers
npm ci --ignore-scripts
npm run build
npm link
sync-servers --version

A first sync in two commands

sync-servers site add --name "My Site" --local-root ~/sites/my-site \
  --protocol ftps --host 203.0.113.10 --user demo-user@example.com
cd ~/sites/my-site && sync-servers sync --put

On Windows, in cmd.exe:

sync-servers site add --name "My Site" --local-root "C:\Users\<user>\Sites\my-site" ^
  --protocol ftps --host 203.0.113.10 --user demo-user@example.com

site add asks for the password, connects, and asks about anything only a person can decide: an SSH host key or a TLS certificate seen for the first time, and the folder on the server that holds the site, starting where the server opens. With no options it asks for everything. The last command scans both sides and opens the preview: check what should move, then press Enter.

Prefer menus? Run sync-servers with no command to add sites and servers, test a connection and synchronize, all from the keyboard.

Where to next