vim a.sh
#!/bin/bash
file1=/tmp/a/
inotifywait -mrq --timefmt '%d/%m/%y-%H:%M' --format '%T %w%f' -e modify,delete,create,attrib ${file1} | while read file
do
rsync -az --delete ${file1} *.*.*.*:${file1}
done
sh a.sh &
vim a.sh
#!/bin/bash
file1=/tmp/a/
inotifywait -mrq --timefmt '%d/%m/%y-%H:%M' --format '%T %w%f' -e modify,delete,create,attrib ${file1} | while read file
do
rsync -az --delete ${file1} *.*.*.*:${file1}
done
sh a.sh &