解决 git 问题:fatal: not a git repository (or any of the parent directories): .git

@[TOC](解决 git 问题:fatal: not a git repository (or any of the parent directories): .git)

1. appear

When using git to add a new remote host today, I found the following error: fatal: not a git repository (or any of the parent directories): .git, as shown in the figure:

insert image description here
The prompt says that there is no such a directory as .git

2. Solutions

Just type in the command line git initand Enter

insert image description here

Guess you like

Origin blog.csdn.net/a6661314/article/details/125722314