Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

2
  • 6
    One tip is to copy your .git/config file if you have added remote origin, before deleting the folder.
    – Tiago
    Commented Mar 8, 2010 at 23:15
  • 5
    @ChrisJohnsen comment is spot on. Sometimes, you want to commit all files except one: git add -A && git rm --cached EXCLUDEFILE && git commit -m 'awesome commit' (This also works when there's no previous commits, re Failed to resolve 'HEAD' problem)
    – user246672
    Commented Mar 29, 2013 at 4:20