zifeo / whiz

Modern DAG/tasks runner for multi-platform monorepos with live reloading, env management, pipes, and more in a tabbed view.
https://metatype.dev/docs/reference/ecosystem?utm_source=github&utm_medium=about&utm_campaign=whiz
Mozilla Public License 2.0
19 stars 14 forks source link

Replace globset with glob-match in watcher.rs and command.rs #99

Open abdiu34567 opened 10 months ago

abdiu34567 commented 10 months ago

Fixes #24

Pull Request: Replace globset with glob-match

Overview:

This pull request proposes replacing the globset library with the glob-match library in the whiz repository.

Changes:

  1. Files Modified:

    • watcher.rs: Implemented glob-match logic, replacing all instances of globset. Ensured that the watcher functionality continues to operate as expected by testing for file changes.
    • command.rs: Removed unused imports related to globset and ensured that the integration with glob-match is seamless. Also made necessary adjustments to data structures (e.g., replacing GlobSet with Vec<String> for pattern storage).
  2. Package Changes:

    • Added: glob-match – An efficient and fast glob matching library.
    • Removed: globset – The previous glob matching library.

Reason for Change:

The glob-match library provides an extremely efficient matching mechanism with zero allocations, no regex compilation, and a linear-time matching process. It's a lightweight and robust alternative to globset.

Testing:

Would appreciate a review to ensure the changes are aligned with the repository's standards and objectives. Feedback is welcome.