当前位置:   article > 正文

【Git】报错处理:fatal: detected dubious ownership in repository at .....Set the environment variable GIT_T_detected dubious ownership in repository at 'c:/us

detected dubious ownership in repository at 'c:/users/administrator/ideaproj

【Git】报错处理:fatal: detected dubious ownership in repository at .....

异常信息

Windows PowerShell
版权所有 (C) Microsoft Corporation。保留所有权利。

尝试新的跨平台 PowerShell https://aka.ms/pscore6

PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> 
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> 
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> git pull
fatal: detected dubious ownership in repository at 'C:/Users/Administrator/Desktop/she_qu_tuan_gou/_work/drivers'
To add an exception for this directory, call:

        git config --global --add safe.directory C:/Users/Administrator/Desktop/she_qu_tuan_gou/_work/drivers    

Set the environment variable GIT_TEST_DEBUG_UNSAFE_DIRECTORIES=true and run
again for more information.
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> 
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> 
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> git config --global --add safe.directory C:/Users/Administrator/Desktop/she_qu_tuan_gou
/_work/drivers
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> 
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> git pull
Already up to date.
PS C:\Users\Administrator\Desktop\she_qu_tuan_gou\_work\drivers> 

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24

解决

git config --global --add safe.directory C:/Users/Administrator/Desktop/she_qu_tuan_gou/_work/drivers 
  • 1

在这里插入图片描述

本文内容由网友自发贡献,转载请注明出处:【wpsshop博客】
推荐阅读
相关标签
  

闽ICP备14008679号