bee4785
# the amount of time, in seconds, to wait before trying the handler
bee4785
# again.  If not specified, it defaults to 300, which is 5 minutes.
bee4785
# delay_time 300
bee4785
#
bee4785
# the number of repeats it should try before giving up.  This can
bee4785
# be 0, meaning infinite retries.
bee4785
# delay_repeats 0
bee4785
#
bee4785
# An example of watch section follows
bee4785
watch {
bee4785
#      
bee4785
#    # watch the ~/drop directory for new files
bee4785
#    ~/drop {
bee4785
#        # matches any mimetype beginning with image/
bee4785
#        image/* {
bee4785
#            # %% is replaced with the filename of the new file
bee4785
#            handler = echo found an image: %%
bee4785
#        }
bee4785
#
bee4785
#        # matches any file ending with .extension
bee4785
#        *.extension {
bee4785
#            # the filename is added to the end of the handler line if %% is not present
bee4785
#            handler = echo glob handler 1: 
bee4785
#            # the second handler will be run if the first exits with a return code of 1
bee4785
#            handler = echo glob handler 2: %%
bee4785
#        }
bee4785
#
bee4785
#        # run handlers on files that match this regex
bee4785
#        /.*regex.*/ {
bee4785
#            handler = echo regex handler
bee4785
#        }
bee4785
#
bee4785
#        # generic handler to catch files that nothing else did
bee4785
#        * {
bee4785
#            handler = mv %% ~/downloads/
bee4785
#        }
bee4785
#    }
bee4785
#
bee4785
}