# hound

> Cross platform directory tree watcher, focussed on reliability, speed, and simplicity.

Latest version **1.0.5** (published 2017-03-24) · 0 weekly downloads

## Install

```sh
npm install hound
pnpm add hound
yarn add hound
bun add hound
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.5 |
| Published | 2017-03-24 |
| First published | 2012-05-20 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=0.7.1 |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 97 |
| Author | Michael Alexander |
| Maintainers | beefsack, gforceg |
| Keywords | directory, tree, watch, windows, cross, platform, reliable, simple, fast |

## Links

- npm: https://www.npmjs.com/package/hound
- Repository: https://github.com/beefsack/node-hound
- Issues: https://github.com/beefsack/node-hound/issues
- npm.io page: https://npm.io/package/hound

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 1.0.5 (latest) — 2017-03-24
- 1.0.4 — 2012-06-28
- 1.0.3 — 2012-06-28
- 1.0.2 — 2012-05-24
- 1.0.1 — 2012-05-21
- 1.0.0 — 2012-05-20

## README

hound - directory tree watcher for node.js
=============================================

Cross platform directory tree watcher that works, even on Windows
-----------------------------------------------------------------

The philosophy of hound is:

* **Be reliable, work on every platform**
* **Be fast**
* **Be simple**

hound is designed to be very reliable, fast, and simple.  There are no runtime
dependencies outside of the standard node.js libraries.  There is a development
dependency on [Jasmine](http://pivotal.github.com/jasmine/), which is required
to run the tests.

Installation
------------

Install using npm:

```
npm install hound
```

Because hound has no runtime dependencies, it is also possible to download the
library manually and require it directly.

Usage
-----

```javascript
hound = require('hound')

// Create a directory tree watcher.
watcher = hound.watch('/tmp')

// Create a file watcher.
watcher = hound.watch('/tmp/file.txt')

// Add callbacks for file and directory events.  The change event only applies
// to files.
watcher.on('create', function(file, stats) {
  console.log(file + ' was created')
})
watcher.on('change', function(file, stats) {
  console.log(file + ' was changed')
})
watcher.on('delete', function(file) {
  console.log(file + ' was deleted')
})

// Unwatch specific files or directories.
watcher.unwatch('/tmp/another_file')

// Unwatch all watched files and directories.
watcher.clear()
```

Testing
-------

To run the tests, use `npm test`.  The tests work on actual directory trees that
are generated in the tmp directory.

---
_Source: https://npm.io/package/hound · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
