Skip to content

Instantly share code, notes, and snippets.

Avatar
🛠️
Building

electo FaysalM

🛠️
Building
View GitHub Profile
@FaysalM
FaysalM / rsync-retry.sh
Last active Aug 29, 2015 — forked from iangreenleaf/rsync-retry.sh
rsync with retries
View rsync-retry.sh
#!/bin/bash
### ABOUT
### Runs rsync, retrying on errors up to a maximum number of tries.
### Simply edit the rsync line in the script to whatever parameters you need.
# Trap interrupts and exit instead of continuing the loop
trap "echo Exited!; exit;" SIGINT SIGTERM
MAX_RETRIES=50