-
-
Save psqq/78395e743bbbb556df33 to your computer and use it in GitHub Desktop.
Looks for file changes in the current directory
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
inotifywait -m $PWD -r -e create -e moved_to -e delete | | |
while read path action file; do | |
TITLE="Filesystem changed" | |
MESSAGE="The file '$file' appeared in directory '$path' via '$action'" | |
echo ${MESSAGE} | |
notify-send "${TITLE}" "${MESSAGE}" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment