I am trying to delete a created file with inotify but it doesn't work:
inotifywait -r --format '%w%f' -e create /test && rm $FILE
when i create a file in /test I get this:
/test/somefile.txt
rm: missing operand
Try `rm --help' for more information.
so it seems that the $FILE variable is not passed to the rm command... how can I do this correctly? Thanks.