Skip to main content

Monitors paths and upon detecting changes runs the specified command

Project description

Monitors paths and upon detecting changes runs the specified command.

Intended for automatically running tests upon code changes, it can also be useful for running any command upon changes to files.

Any number of paths may be monitored and directories will be recursively monitored.

Both white list and black list are supported to refine exactly what paths are monitored, with the white list taking precedence over the black list.

By default an initial command run is performed but this can be turned off.

In addition any file changes detected during a command run can be discarded at the end of the run to avoid an immediate rerun.

Nosier uses the Linux inotify facility for monitoring paths and as such it doesn’t put as much load on the cpu and disk compared to regularly scanning and calculating checksums.

Further it can act immediately upon file changes rather than waiting for the next scan. By default there is a small delay of 0.1 second before performing a command run in order to collect file changes that occur very close together.

It is however limited to Linux 2.6 since it depends on the inotify facility.

To run py.test upon changes:

nosier py.test tests

To run nose upon changes:

nosier nosetests tests

To rsync a project to another host upon changes (note quotes are required here for the options passed to rsync):

nosier "rsync -av awesome_project remote_host:/work/area/"

Installation with pip:

pip install nosier

Installation with easy install:

easy_install nosier

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
nosier-1.1.tar.gz (5.1 kB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page