NAME

CSS::Watcher::Monitor - Monitor files for changes.

SYNOPSIS

use CSS::Watcher::Monitor;
my $cm = CSS::Watcher::Monitor->new (dir => '/foo/bar');

# return num of files modified
$cm->scan(
          sub {
              my $file = shift;
              # process changed file or first scan new file
              } );

DESCRIPTION

Watch for changes, call callback sub. Call callback on first scan too.

SEE ALSO

File::Monitor - I get some patterns from there

AUTHOR

Olexandr Sydorchuk (olexandr.syd@gmail.com)

COPYRIGHT AND LICENSE

Copyright (C) 2014 by Olexandr Sydorchuk

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.2 or, at your option, any later version of Perl 5 you may have available.