-1

It started with the clone of a GitHub repository of the excellent "Jonas Schmedtmann" course about Nodejs on Udemy.

And after completed the first exercise which is an API, my plan was to create my own git local repository and send it online on my GitHub account.

But I did the really wrong way...
And as always I used to struggle a lot with the use of Git and Github, and I mess up with the work I did.

So I had the bad idea to first delete the .git to unlink the initial local and distant repository, then I created new one with a git init to upload my work on my own repository.

Nothing worked as expected.... and I have deleted everything with a "rm -rf .git" thinking it will solve something.
But i cannot get rid of this in VsCode.enter image description here

I don't know what it means and what can i do to fully clean the repo to start over.

Problem: Why do I still see Git indicators after having deleted the .git/ subfolder of my local repository?

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
filouDcode
  • 33
  • 5
  • 1
    You mean what `master !2 ?8` means? It's nothing to do with VS Code, that's some shell plugin you have showing you the current repo status - run `git status` to get a more verbose representation. – jonrsharpe Feb 11 '23 at 15:59
  • but i don't understand why i'm still located on a branch (master) as i don't have .git file anymore in the root folder, and what mean !2 and?8 – filouDcode Feb 11 '23 at 16:15
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Feb 13 '23 at 07:20

2 Answers2

3

This comes from the Oh My Posh Git segment used by posh-git, indicating unstaged files (2!) or untracked files (?8)

why I am still located on a branch (master) as I don't have .git file anymore in the root folder,

  • First it is a (hidden) .git folder, not file.
  • Second, there should be a .git folder either in /starter, or in /.
    That or there is a GIT_DIR environment variable referencing a Git repository somewhere else.
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
-1

finally, after some research i did :

  1. "git reset --hard" to reset the current branch tip, it first removed !2
  2. "git clean -df" to Delete all untracked files and directories, and it removed ?8

if it can help hard beginner like me.....

filouDcode
  • 33
  • 5