Git: fatal: bad config file line 1 in .git/config

  • Post author:
  • Post category:其他


An error shows in the Jenkins’ project console as:

ERROR: Workspace has a .git repository, but it appears to be corrupt.
hudson.plugins.git.GitException: Command "C:\Program Files (x86)\Git\cmd\git.exe rev-parse --is-inside-work-tree" returned status code 128:
stdout: 
stderr: fatal: bad config file line 1 in .git/config

failed to fetch the code from the remote git repository.

Solution:

Copy config file from another local git repository for the same remote git repository.



版权声明:本文为simzha01原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。