PHPackages                             flow-control/react-inotify - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. flow-control/react-inotify

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

flow-control/react-inotify
==========================

Event-driven inotify streams for non-blocking I/O in ReactPHP

v2.2.1(3mo ago)58.3k1MITPHPPHP ^8.0CI failing

Since Aug 9Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/realFlowControl/react-inotify)[ Packagist](https://packagist.org/packages/flow-control/react-inotify)[ RSS](/packages/flow-control-react-inotify/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (8)Dependencies (10)Versions (13)Used By (0)

flow-control/react-inotify
==========================

[](#flow-controlreact-inotify)

[![Build Status](https://camo.githubusercontent.com/89eb1f66a12adbad057f4e97ce843c433a55e8da00d17af82ed6dde31511723c/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f666c6f772d636f6e74726f6c2f72656163742d696e6f746966792f63692e796d6c3f7374796c653d666f722d7468652d6261646765266c6f676f3d676974687562253230616374696f6e73266272616e63683d6d6173746572)](https://github.com/flow-control/react-inotify/actions)[![Coverage](https://camo.githubusercontent.com/7fc5cc1a778ab2bcda6454702a41b392711a07dd6769a2018cf3605b293eaf63/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f666c6f772d636f6e74726f6c2f72656163742d696e6f746966793f7374796c653d666f722d7468652d6261646765266c6f676f3d636f6465636f76)](https://codecov.io/gh/flow-control/react-inotify)[![PHP Version](https://camo.githubusercontent.com/76d1cdec43e1192a1758f039f63f9215ea9a3acdda93fda51656f93909d0f67d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f666c6f772d636f6e74726f6c2f72656163742d696e6f746966792e7376673f7374796c653d666f722d7468652d6261646765)](https://github.com/flow-control/react-inotify)[![Stable Version](https://camo.githubusercontent.com/361ec5d9995a4568a7f68b41059bbd81d9cdc1d951255373da8e52083add4ea1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f666c6f772d636f6e74726f6c2f72656163742d696e6f746966792e7376673f7374796c653d666f722d7468652d6261646765266c6162656c3d4c6174657374)](https://packagist.org/packages/flow-control/react-inotify)

Simple, async inotify event handler build with ReactPHP

This library is heavily inspired by [reactphp/stream](https://github.com/reactphp/stream).

Dependencies
------------

[](#dependencies)

This library depends on the [PHP Inotify extension](https://pecl.php.net/package/inotify), available via PECL

```
$ pecl install inotify
```

PHP Version Support
-------------------

[](#php-version-support)

If you are looking for PHP 7 support you need to install `flow-control/react-inotify` in version 1. Version 2 dropped support for PHP 7.

Usage
-----

[](#usage)

### Install

[](#install)

```
$ composer require flow-control/react-inotify
```

### How to use

[](#how-to-use)

Create an object from the `\Flowcontrol\React\Inotify\InotifyStream` class and register your event handlers.

```
$inotify = new \Flowcontrol\React\Inotify\InotifyStream();
$inotify->on('event', function (array $data) {
    var_dump($data);
});
$inotfiy->addWatch(__DIR__, IN_CLOSE_WRITE);
```

Tests
-----

[](#tests)

```
$ composer install
$ composer test
```

Build with
----------

[](#build-with)

- [ReactPHP](https://reactphp.org/)
- [evenement/evenement](https://github.com/igorw/evenement)

License
-------

[](#license)

MIT, see [LICENSE file](LICENSE).

###  Health Score

50

—

FairBetter than 95% of packages

Maintenance80

Actively maintained with recent releases

Popularity24

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity71

Established project with proven stability

 Bus Factor1

Top contributor holds 98.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~301 days

Recently: every ~474 days

Total

9

Last Release

105d ago

Major Versions

v1.1.1 → v2.0.02022-01-06

PHP version history (4 changes)v1.0.0PHP ^7.2

v1.1.0PHP ^7.2|^8

v2.0.0PHP ~8.0.0|~8.1.0

v2.1.0PHP ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/4077e948019ad1210ab647b1d760d3eb9c21af633b62536696d9f4223c5308c0?d=identicon)[realFlowControl](/maintainers/realFlowControl)

---

Top Contributors

[![realFlowControl](https://avatars.githubusercontent.com/u/14161194?v=4)](https://github.com/realFlowControl "realFlowControl (108 commits)")[![devnix](https://avatars.githubusercontent.com/u/1777519?v=4)](https://github.com/devnix "devnix (2 commits)")

---

Tags

filewatcherinotifyreactphpnon-blockingreactphpevent-driveninotify

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/flow-control-react-inotify/health.svg)

```
[![Health](https://phpackages.com/badges/flow-control-react-inotify/health.svg)](https://phpackages.com/packages/flow-control-react-inotify)
```

###  Alternatives

[react/stream

Event-driven readable and writable streams for non-blocking I/O in ReactPHP

691146.0M209](/packages/react-stream)[friendsofphp/php-cs-fixer

A tool to automatically fix PHP code style

13.5k251.2M24.7k](/packages/friendsofphp-php-cs-fixer)[react/child-process

Event-driven library for executing child processes with ReactPHP.

34691.0M157](/packages/react-child-process)[ccxt/ccxt

A cryptocurrency trading API with more than 100 exchanges in JavaScript / TypeScript / Python / C# / PHP / Go

43.2k341.0k1](/packages/ccxt-ccxt)[react/react

ReactPHP: Event-driven, non-blocking I/O with PHP.

9.1k3.7M65](/packages/react-react)[react/http

Event-driven, streaming HTTP client and server implementation for ReactPHP

78127.7M461](/packages/react-http)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
