From 8486e77b92af3ff607a17268ba5f467c6979286e Mon Sep 17 00:00:00 2001 From: Yonas Worku <92879873+YonasWorku2224@users.noreply.github.com> Date: Fri, 21 Feb 2025 21:40:26 -0500 Subject: [PATCH] Improved README Updated the README file by adding installation instructions, basic usage guide, and common use cases --- README.markdown | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/README.markdown b/README.markdown index f37d8a3f425e..3d73be6562d0 100644 --- a/README.markdown +++ b/README.markdown @@ -9,6 +9,50 @@ Watchman exists to watch files and record when they actually change. It can also trigger actions (such as rebuilding assets) when matching files change. +## Installation Instructions + +macOS (via Homebrew) +```bash +brew install watchman +``` + +Linux (Ubuntu) +```bash +sudo apt update && sudo apt install watchman +``` + +Windows +Download the latest release from the https://github.com/facebook/watchman/releases and follow the instalation instructions. + +## Basic Usage Guide +Once installed, you can verify Watchman is running: +```bash +watchman version +``` + +To start watching a directory: +```bash +watchman watch /path/to/directory +``` + +## Common Use Cases + +Automated Asset Compilation +* Watchman can be used to automatically detect file changes and trigger actions like rebuilding assets (e.g., compiling JavaScript, CSS, or other project files) + +Efficient Testing Workflows +* Many testing frameworks (such as Jest) integrate with Watchman to rerun tests whenever a file changes + +* This speeds up the development process by allowing real-time feedback instead of manually restarting tests + +Version Control Integration +* It can be used to track changes in Git repositories + +* Watchman helps to identify modified files and can be configured to alert teams or run scripts when changes occur + +File Synchornization and Backup +* Watchman can be used to monitor directories and sync changes across different environments + ## Documentation Head on over to https://facebook.github.io/watchman/