Simple sync files realization with goroutines between two directories.
To create exec file, type make command
make build
To see available command arguments:
./gosync -help
Usage of ./gosync:
-initial string
Initial directory
-interval int
Interval in minutes between checking initial directory (default 5)
-target string
Target directory to copy files from initial
To start sync initial folder:
make build
and
./gosync -initial=/Users/username/Desktop/first-directory -target=/Users/username/Desktop/target -interval=10
or
go run cmd/app/main.go -initial=/Users/username/Desktop/first-directory -target=/Users/username/Desktop/target -interval=10