Skip to content

A multithreaded bidirectional file synchronization script written in bash with minimal dependencies

License

Notifications You must be signed in to change notification settings

IsaacElenbaas/bbsync

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bbsync

About

bbsync is a multithreaded bidirectional file synchronization script written in bash with minimal dependencies. It uses http(s) for transfers to straightforwardly be available behind most firewalls.

Symlinks are followed when updating their contents, but are created as normal files/folders if they do not exist on the other end.

Demo

I use it to sync files between various machines while maintaining one master copy. Inspired in part by bsync.

Dependencies

  • GNU Coreutils
  • bash 4 or above
  • find
  • curl
  • node-js

Usage

./bbsync [OPTIONS]
  --connect-timeout NUM     maximum time in seconds to allow connection attempts
  -d, --dry-run             perform a trial run with no changes made
  --force [push, pull]      ignore master/local state
  --max-time NUM            maximum time in seconds to allow transfers
  --minshow NUM             minimum time in seconds to show actions
  --no-progress             do not show progress during transfer
  -p, --processes NUM       number of processes to use
  --server URL              master server URL
  -v, --verbose             output a diagnostic for every file that will be processed
  -h, --help                display this help

Clients will only sync folders present in the sync folders of both ends of the connection.

Downsides

  • No moved files detection
  • File ownership is ignored, although missing write permissions is handled
  • It is assumed that files will be changed only on one end before a sync due to the 'master server' philosophy

About

A multithreaded bidirectional file synchronization script written in bash with minimal dependencies

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published