From 80f402e2b60fe04a6470b2ce8ef665fc8d855dc4 Mon Sep 17 00:00:00 2001 From: Jon Meow <46229924+jonmeow@users.noreply.github.com> Date: Fri, 28 Jan 2022 18:20:05 -0800 Subject: [PATCH] Warn about watchman (#1052) --- docs/project/contribution_tools.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/project/contribution_tools.md b/docs/project/contribution_tools.md index fa49f45f84c6..a7d536ff25a5 100644 --- a/docs/project/contribution_tools.md +++ b/docs/project/contribution_tools.md @@ -61,8 +61,6 @@ typical tool setup flow is: https://github.com/carbon-language/carbon-lang. - `gh repo clone USER/carbon-lang`, or otherwise clone the fork. - `cd carbon-lang` to go into the cloned fork's directory. - - `git config core.fsmonitor rs-git-fsmonitor` to set up - [rs-git-fsmonitor](#rs-git-fsmonitor-and-watchman) in the clone. - `pre-commit install` to set up [pre-commit](#pre-commit) in the clone. 4. Validate your installation by invoking `bazel test //...:all' from the project root. All tests should pass. @@ -329,6 +327,10 @@ repositories. See the page for installation instructions. ### `rs-git-fsmonitor` and Watchman +> **WARNING**: Bugs in `rs-git-fsmonitor` and/or Watchman can result in +> `pre-commit` deleting files. If you see files being deleted, disable +> `rs-git-fsmonitor` with `git config --unset core.fsmonitor`. + [rs-git-fsmonitor](https://github.com/jgavris/rs-git-fsmonitor) is a file system monitor that uses [Watchman](https://github.com/facebook/watchman) to speed up git on large repositories, such as `carbon-lang`.