Skip to content

Instantly share code, notes, and snippets.

@mgiacomini
Created November 5, 2014 16:29
Show Gist options
  • Save mgiacomini/d02fa6cb5a54560362b5 to your computer and use it in GitHub Desktop.
Save mgiacomini/d02fa6cb5a54560362b5 to your computer and use it in GitHub Desktop.
Sync files
#!/bin/bash
echo "Sync files"
echo "------------------------------------"
if [ "$1" = "" || $2 = "" ]; then
echo "Source/Dest path can not be null"
exit
fi
rsync -avzhe ssh --progress --exclude-from .emid_ignore $1 $2
echo "------------------------------------"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment