Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Remove old and add new git in android studio

Tags:

I have tried to configure android studio with git and messed up.

How to completely remove old git that I could create new one?

like image 996
user345280 Avatar asked Aug 13 '15 14:08

user345280


People also ask

How do I remove a Git repository and add new?

Just run the rm command with the -f and -r switch to recursively remove the . git folder and all of the files and folders it contains. This Git repo remove command also allows you to delete the Git repo while allowing all of the other files and folder to remain untouched.


1 Answers

In order to drop the current git repository and create a new one you need to:

  • Go to the project's directory: cd PROJECT_DIRECTORY

  • Remove all the git specific files: rm -rf $(find . -name ".git*")

  • Initialize a new git repository: git init

This doesn't remove your project's files, only git configs

like image 162
neshkeev Avatar answered Sep 28 '22 16:09

neshkeev