Skip to main content
Python Software Foundation 20th Year Anniversary Fundraiser  Donate today!

multi-files watcher

Project description

the file watch


  • capable to watch multi files at the same time.
  • base on pyinotify
  • easy to use


$ pip install thefilewatch

how to use

import sys
from thefilewatch.file_watch import BaseWatchHandler, FileWatch

class PrintHandler(BaseWatchHandler):

    def process(self, content):
        print('getting content ', content)

if __name__ == '__main__':
    if len(sys.argv) < 2:
        print('need watch files')
        file_list = sys.argv[1:]
    watcher = FileWatch(file_list, PrintHandler())

start watching files

$ python -m thefilewatch.file_watch a.txt b.txt


see more specific examples in handler

Project details

Download files

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

Files for thefilewatch, version 0.0.8
Filename, size File type Python version Upload date Hashes
Filename, size thefilewatch-0.0.8.tar.gz (2.5 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page