Skip to main content

surveiler

Very simple file-watching utility.

Installation

(coming soon) pip: pip install surveiler

Or just copy the file locally (it's literally 60 lines)

Usage

Two exported functions: make_event_handler, surveil. Signatures (not exactly):

def make_event_handler(**kw: dict[str, Callable[[], None]]) -> Callable[[int], None]: ...
def surveil(directory_name: str, event_handler: Callable[[int], None]) -> Never: ...

Example usage:

event_handler = make_event_handler(on_create=lambda: print('create'), on_modify=lambda: print('modify'))
surveil("testdirec", event_handler)

Check out the constants in the source file to see what event handlers you can add; any one of them can be adapted to a keyword argument to event_handler. Example: IN_MOVE -> on_move.

Metadata

Release files for surveiler 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for surveiler 1.0.0
File Size Uploaded Provenance
surveiler-1.0.0.tar.gz 3.1 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for surveiler 1.0.0
File Interpreter ABI Platform
surveiler-1.0.0-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 6.4 kB

Release files / surveiler-1.0.0.tar.gz

Download URL surveiler-1.0.0.tar.gz
Size 3.1 kB
Tags Source
SHA-256 checksum
How to use checksums
e9db2ad338b8046a1e73e2d85f8948602b83e6dd786693fd05dbf98c3c265272
BLAKE2b-256 checksum
How to use checksums
4cb2715ac6cac4ab643adc87a679b15b4caea854dd31cdec83a2f962b5e85ea7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-requests/2.28.2

Release files / surveiler-1.0.0-py2.py3-none-any.whl

Download URL surveiler-1.0.0-py2.py3-none-any.whl
Size 3.2 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
2df8555e240d7e6140830fde8caafc9d46bba059dfd9d12a6c9b3527aa0f2f06
BLAKE2b-256 checksum
How to use checksums
c96e4761e3ef19f19d0f3e63cb5cdd60b4ba8c7510191fe37c6a316b4a2bee9f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-requests/2.28.2

Security for surveiler 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page