Linux Today: Linux News On Internet Time.

More on LinuxToday

Scheduling Jobs Based on Filesystem Activity With Incron

Aug 21, 2008, 22:02 (0 Talkback[s])
(Other stories by Shashank Sharma)


Desktop-as-a-Service Designed for Any Cloud ? Nutanix Frame

"If you want the system to play an audio file whenever a new file/directory is created in your home directory, use this incrontab entry: /home/linuxlala IN_CREATE paplay /usr/share/sounds/pop.wav. The command /home/linuxlala IN_CREATE rm -rf $@/$# works similarly but its purpose is far more evil. With this entry in the incrontab file, any directory or file created in the user's home directory would be immediately deleted. The special symbols, or wildcards ($@/$#), convey the complete path of the newly created file to the rm -rf command."

Complete Story

Related Stories: