3

I run git add . and then it does nothing for a while, and then says error: daemon terminated. This happens with all commands, not just git add How do I fix that? git status does show a bit of information about changes to be committed, but still shows the same error

Logos King
  • 121
  • 1
  • 6
  • There is no daemon involved with git commands like `add` or `status`. To unravel what's going on, you will probably need to include more about your environment / system. Something other than the usual git package must be involved here. – Dan Lowe Nov 25 '22 at 04:18
  • following your advice, simply uninstalling and reinstalling git fixed the issue – Logos King Nov 25 '22 at 07:43
  • @LogosKing Well done. I have included your comment in the answer for more visibility. – VonC Nov 25 '22 at 09:06
  • 1
    @DanLowe: there's a fancy new file system monitor that's intended to make Git go faster. For a long time it's been off by default, but it looks like it's now on by default on Windows. If it's misbehaving, the quickest thing is to just turn it off, since it's purely optional and is merely *intended* to make Git faster; whether it does, and if so how much, is another question entirely... :-) – torek Nov 25 '22 at 12:37

1 Answers1

4

There is indeed a daemon starting with Git 2.34 (Q4 2021), for the fsmonitor, using the Simple-IPC protocol.

Check the version of Git used and, in case this is is a bug, try and upgrade it to the latest 2.38.1.

(Which is closed to what the OP Logos King mentions in the comments: "simply uninstalling and reinstalling git fixed the issue")

Check also the value of git config core.fsmonitor (done from within your repository folder). Try and set it to false to see if the issue persists.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250