wp2static/provisioning/watch_source_files.sh

10 lines
262 B
Bash
Raw Normal View History

2017-02-20 11:57:08 +13:00
#!/bin/bash
2017-02-20 12:23:02 +13:00
inotifywait -rm --event modify --format '%w%f' --exclude '.*\.swp.*' /app |
while read filename; do
echo 'a file has changed!'
echo $filename
2017-02-20 12:26:49 +13:00
# TODO: better here would just be to perform rsync on the one file
2017-02-20 11:57:08 +13:00
. /sync_sources.sh
done