Module: FileMonitoring
- Defined in:
- lib/file_monitoring.rb,
lib/file_monitoring/version.rb,
lib/file_monitoring/monitor_path.rb,
lib/file_monitoring/file_monitoring.rb
Overview
Daemon for monitoring directories for changes. Paths are checked for changes per user-defined period of time.
Directory defined changed when:
-
Directory structure changed, i.e. sub-directories or files were added/removed
-
One of the files located in the directory or one of its sub-directories was changed
-
One of sub-directories changed (see 1. and 2. above)
File monitoring controled by following configuration parameters:
-
default_monitoring_log_path
- holds path of file monitoring log. This log containd track of changes found during monitoring -
monitoring_paths
- path and file monitoring configuration data regarding these paths.
Defined Under Namespace
Classes: DirStat, FileMonitoring, FileStat, FileStatEnum, IdentFileInfo
Constant Summary collapse
- VERSION =
"1.4.1"
- @@stable_state =
Number of iterations to move state from UNCHANGED to STABLE (for index)
10
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.stable_state ⇒ Object
44 45 46 |
# File 'lib/file_monitoring/monitor_path.rb', line 44 def self.stable_state @@stable_state end |
.stable_state=(stable_state) ⇒ Object
40 41 42 |
# File 'lib/file_monitoring/monitor_path.rb', line 40 def self.stable_state=(stable_state) @@stable_state = stable_state end |
Instance Method Details
#monitor_files ⇒ Object
27 28 29 30 |
# File 'lib/file_monitoring.rb', line 27 def monitor_files fm = FileMonitoring.new fm.monitor_files end |