# Monitoring the directory

**URL:** <https://rubytalk.org/t/monitoring-the-directory/52422>\
**Category:** ruby-talk\
**Created:** [21 March 2009 07:08 UTC](https://rubytalk.org/t/monitoring-the-directory/52422 "2009-03-21T07:08:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Loga\_Ganesan](https://avatars.discourse-cdn.com/v4/letter/l/74df32/32.png) [@Loga\_Ganesan](https://rubytalk.org/u/Loga_Ganesan)\
**Post date:** [21 March 2009 07:08 UTC](https://rubytalk.org/t/monitoring-the-directory/52422/1 "2009-03-21T07:08:39Z")

</div>

Hi  
&nbsp;&nbsp;&nbsp;Is there any pre-defined module available in ruby to monitor a given  
directory.

monitoring in the sense,  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\* When ever a new file is created or removed inside that  
directory  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\* When ever a new directory is created or removed inside that  
directory

Likewise , is there any standard module available in ruby to monitor a  
file growth

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).

---

<div class="post-metadata">

**Author:** ![Sean\_O\_Halpin](https://avatars.discourse-cdn.com/v4/letter/s/ac91a4/32.png) [@Sean\_O\_Halpin](https://rubytalk.org/u/Sean_O_Halpin)\
**Post date:** [21 March 2009 14:30 UTC](https://rubytalk.org/t/monitoring-the-directory/52422/2 "2009-03-21T14:30:58Z")

</div>

$ sudo gem install directory\_watcher file-tail

> **[GitHub - TwP/directory\_watcher: Event notification for file system changes](https://github.com/TwP/directory_watcher/tree/master)**
>
> master

[http://file-tail.rubyforge.org/](http://file-tail.rubyforge.org/)

HTH  
Sean

> **···**
>
> On Sat, Mar 21, 2009 at 7:08 AM, Loga Ganesan \<loganathan\_gpt@yahoo.co.in\> wrote:
> 
> > Hi  
> > Is there any pre-defined module available in ruby to monitor a given  
> > directory.
> > 
> > monitoring in the sense,  
> > \* When ever a new file is created or removed inside that  
> > directory  
> > \* When ever a new directory is created or removed inside that  
> > directory
> > 
> > Likewise , is there any standard module available in ruby to monitor a  
> > file growth

---

<div class="post-metadata">

**Author:** ![Loga\_Ganesan](https://avatars.discourse-cdn.com/v4/letter/l/74df32/32.png) [@Loga\_Ganesan](https://rubytalk.org/u/Loga_Ganesan)\
**Post date:** [23 March 2009 12:20 UTC](https://rubytalk.org/t/monitoring-the-directory/52422/3 "2009-03-23T12:20:31Z")

</div>

Sean O'halpin wrote:

> **···**
>
> > On Sat, Mar 21, 2009 at 7:08 AM, Loga Ganesan \> \<loganathan\_gpt@yahoo.co.in\> wrote:
> > 
> > > Likewise , is there any standard module available in ruby to monitor a  
> > > file growth
> > 
> > $ sudo gem install directory\_watcher file-tail
> > 
> > [GitHub - TwP/directory\_watcher: Event notification for file system changes](http://github.com/TwP/directory_watcher/tree/master)
> > 
> > [http://file-tail.rubyforge.org/](http://file-tail.rubyforge.org/)
> > 
> > HTH  
> > Sean
> 
> Ya both the modules are working fine. Thank you for your reply.  
> --  
> Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).
