-1

Accidentally I've created some files in /dev/projectname/projectname

I've initiated git repo git remote add origin git@bitbucket...

then i did this from /dev:

mv projectname projectname_d
mv projectname_d/projectname projectname
rm -rf projectname_d

Then i've found out, that repo is located in /dev somehow, so if i run git status it lists all folders in /dev

How do i fix this?

stkvtflw
  • 12,092
  • 26
  • 78
  • 155
  • 1
    Possible duplicate of [How to remove a directory in my GitHub repository?](http://stackoverflow.com/questions/6313126/how-to-remove-a-directory-in-my-github-repository) – Varun Kumar Oct 16 '16 at 12:28

2 Answers2

2

Try rm -r .git from the repo root

WillKre
  • 6,280
  • 6
  • 32
  • 62
2

All the information about that git repository are stored in the .git subdirectory of your project.

If you want to completely un-version a directory you should remove that subdirectory with

rm -rf .git

Running git status you'll see that that directory is "Not a git repository"

David
  • 2,987
  • 1
  • 29
  • 35