Why is there a .git in my Expo project folder?

#1

I’m trying to learn to use git and was going to add my expo project to a git repo, but noticed that there already was a .git folder and a .gitignore file in the project folder. I’ve tried to find information about why expo does this, without any luck. Does expo use this or can i remove it and make it my own git repo without ruining anything?

#2

Hi @jonssonanton!

Expo initialized a Git repo in your project just so you don’t have to. :slightly_smiling_face: If you want to be sure you’re starting from a clean slate on your own, just run

# removes whole .git directory in the current working directory
rm -rf .git

in your project’s directory. Then you can run git init to initialize a Git repo on your own, but that won’t be different in any way from just using the one that already is there. :slightly_smiling_face: It shouldn’t have any commits or remotes set up.

1 Like
#3

Thanks!

closed #4

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.