Couldn‘t check the working tree for unmerged files because of an error. unsafe repository

比如重装系统后,D中的git项目,重新再拉取的时候,报如下错误 。

Couldn't check the working tree for unmerged files because of an error. unsafe repository ('D:/myFile/code/test/test-core' is owned by someone else) To add an exception for this directory, call: git config --global --add safe.directory D:/myFile/code/test/test-core Set the environment variable GIT_TEST_DEBUG_UNSAFE_DIRECTORIES=true and run again for more information.

到项目 所以目 录打开 git bash,
执行提示中 call: 后面的命令即可:

git config --global --add safe.directory D:/myFile/code/test/test-core

你可能感兴趣的:(java,java)