4 ms·
In that setup entr only watches files that existed when systemd service was first started. So new files won't trigger backup. Something like this should work:
by spatular 8y ago
In that setup entr only watches files that existed when systemd service was first started. So new files won't trigger backup. Something like this should work:
while true; do find $ORG_DIR | entr -d -r rclone sync -v $ORG_DIR $REMOTE:org; done
- ISO-morphism 8y agoThat's constantly polling the filesystem, isn't it? I've never used it myself, but I know systemd has file watching built in. I think using `PathModified=/path/to/org` would also eliminate the need for entr [1]. [1] https://www.freedesktop.org/software/systemd/man/systemd.path.html https://www.freedesktop.org/software/systemd/man/systemd.pat...
- spatular 8y agoIt should re-poll only when a new file is added. In op's usage scenario it won't be very ofthen. The systemd solution may be even better, though it seems there is no way to ignore changes in temporary files that emacs likes to create.