Skip to content
/ pierex Public

lightweight file watcher for Python development

Notifications You must be signed in to change notification settings

ixlammm/pierex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PieReX (Python Re eXecute)

PieReX is a lightweight file watcher for Python development. It monitors files and directories for changes and automatically restarts the given Python script when modifications occur. This helps streamline the development process by reducing manual restarts.

Features

  • Watches for file changes in the specified directories
  • Automatically restarts the Python script when a change is detected
  • Improves development workflow by reducing manual intervention

Installation

You can either install the tool manually by building it first or directly from the PyPI index

Manually

Install packages required for building:

pip install setuptools wheel twine

Build the tool:

python setup.py sdist bdist_wheel 

Then finally install it using pip:

pip install .

From the PyPI Index

pip install pierex

Usage

pierex your_script.py

Optional Flags

  • -d, --dir <path>: Specify the directory to watch (default: current directory)
  • -e, --ext <ext1,ext2>: Watch specific file extensions (default: py)

Example:

pierex -d src -e py,toml my_script.py

Requirements

  • Python 3.6+

How It Works

  1. Pierex monitors the specified directory for changes in relevant files.
  2. When a change is detected, it stops the running Python script.
  3. It restarts the script automatically to reflect the changes.

Contributing

Pull requests and feature suggestions are welcome! Feel free to open an issue if you find a bug or have an idea to improve Pierex.

License

MIT License

About

lightweight file watcher for Python development

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages