React to a modified directory
Posted
by
Ghanshyam Rathod
on Ask Ubuntu
See other posts from Ask Ubuntu
or by Ghanshyam Rathod
Published on 2012-09-24T19:01:42Z
Indexed on
2012/09/24
21:49 UTC
Read the original article
Hit count: 261
In linux everything is considered as file, Now if I want to find only folders/directories not the files then how can i do that?
I am getting all the modified files with the following command.
find /Users/ghanshyam -type f -mmin -5 -print
My goal is to generate the log file with all the modified/access folders. Here two options are available.
create a module and call every time when a folder is modified (this one is bit difficult
because I need to check particular event)create a cron task that will run after every 5 minutes. cron task will execute shell
script and generate the log entries with the modified folders.
Do you have any other option to do this task ?
© Ask Ubuntu or respective owner