I created a git repository with git init. I’d like to delete it entirely and init a new one.
I created a git repository with git init . I’d like to delete it
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Git keeps all of its files in the
.gitdirectory. Just remove that one and init again.If you can’t find it, it’s because it is hidden.
In Windows 7, you need to go to your folder, click on Organize on the top left, then click on Folder and search options, then click on the View tab and click on the Show hidden files, folders and drives radio button.
On a Mac OS:
Open a Terminal (via Spotlight: press CMD + SPACE, type
terminaland press Enter) and run:Note: The keyboard shortcut to show hidden files in Finder is
CMD + SHIFT + . so it is no longer necessary to modify the
finder config this way
You could also type
cd(the space is important), drag and drop your git repo folder from Finder to the terminal window, press return, then typerm -fr .git, then return again.On Ubuntu, use shortcut Ctrl + H.