'How to access init subcommand in github
I was creating my directory on terminal which is;
mkdir root/my-repo
cd root/my-repo
root@shell:-my-repo# git init (//doesn't work)
Reinitialized existing Git repository in /root/my-repo/.git/ (error) Can anyone explain what mistake I made and not not letting me in? Thanks
Solution 1:[1]
When you run the git init command, a hidden folder called .git is created in the directory. You can verify that by running ls -a inside root/my-repo/. If that is the case, you are good to go.
If for some reason you need to create the repo again, you can:
- Create a new folder and run
git init - Detele the
.gitinsideroot/my-repoand rungit initagain
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Bikas |
