Why am I getting the message, “fatal: This operation must be run in a work tree?” December 21, 2022 by Tarik Also, you are probably inside the .git subfolder, move up one folder to your project root.