Readme
Grimoire CSS Watcher
A high-performance file watcher for Grimoire CSS projects. It monitors your Grimoire CSS configuration and automatically rebuilds your CSS whenever changes are detected.
Features
Efficient, non-blocking file watching.
Automatic detection of files from grimoire. config. json .
Smart debouncing to prevent excessive rebuilds.
Clean, colorful logging output.
Lightweight and focused.
Installation
From Crates.io
cargo install grimoire_css_watcher
From GitHub Releases
Pre-compiled binaries for Linux, macOS (x86_64, arm64), and Windows (x86_64) are available on the GitHub Releases page . Download the appropriate binary for your system, make it executable, and place it in your PATH.
Requirements
Grimoire CSS (grimoire_css ) must be installed and available in your PATH.
A valid grimoire. config. json file in your project's grimoire/ config directory (or the root of the project if you modify the watcher's expected path).
Usage
# Run the watcher in the current directory
grimoire_css_watcher
# Specify a different project directory
grimoire_css_watcher --path /path/to/your/project
# Customize the debounce duration (default: 300ms)
grimoire_css_watcher --debounce 500
# Enable verbose logging
grimoire_css_watcher --verbose
Command Line Options
- p, - - path < PATH > : Path to the project directory (defaults to current directory).
- d, - - debounce < MILLISECONDS > : Debounce duration in milliseconds (default: 300).
- v, - - verbose: Enable verbose output.
- h, - - help: Show help information.
--version : Show version information.
How It Works
Reads grimoire/ config/ grimoire. config. json (by default).
Extracts input file patterns.
Watches resolved files and the config file itself.
On change, runs grimoire_css build .
Stops with Ctrl+C.
License
MIT