"Not a git repository"
-
I have tried forking an existing repository, and creating a new empty workspace but I cannot connect to them
$ git remote add origin https://git.codeproject.com/ravenspoint/ws
fatal: Not a git repository (or any of the parent directories): .git -
I have tried forking an existing repository, and creating a new empty workspace but I cannot connect to them
$ git remote add origin https://git.codeproject.com/ravenspoint/ws
fatal: Not a git repository (or any of the parent directories): .gitDid you run 'git init' to initialize your local repository?
-
Did you run 'git init' to initialize your local repository?
Yes. Note the instructions ( Working with CodeProject Workspaces::Code (::GitMachine)[^] ) say to do the init afterwards. I have tried both
-
Yes. Note the instructions ( Working with CodeProject Workspaces::Code (::GitMachine)[^] ) say to do the init afterwards. I have tried both
Did you called 'git remote add' from the repository folder, or from somewhere outside of it? Git clearly said that the local folder was not the repository, I would do a double verification of it.
-
I have tried forking an existing repository, and creating a new empty workspace but I cannot connect to them
$ git remote add origin https://git.codeproject.com/ravenspoint/ws
fatal: Not a git repository (or any of the parent directories): .gitThe problem seems to be with naming the remote as 'origin'. I already use git with another repository. So there is already a remote called 'origin' which causes problems. Things work better if I choose another name
James@MILLER ~/Documents/test4 (master)
$ git remote add t4 https://git.codeproject.com/ravenspoint/dxfvtest4James@MILLER ~/Documents/test4 (master)
$ git remote -v
origin
t4 https://git.codeproject.com/ravenspoint/dxfvtest4 (fetch)
t4 https://git.codeproject.com/ravenspoint/dxfvtest4 (push)James@MILLER ~/Documents/test4 (master)
$ git pull t4 master
remote: Counting objects: 47, done.
remote: Compressing objects: 100% (44/44), done.
remote: Total 47 (delta 8), reused 0 (delta 0)
Unpacking objects: 100% (47/47), done.
From https://git.codeproject.com/ravenspoint/dxfvtest4
* branch master -> FETCH_HEAD
* [new branch] master -> t4/master -
Did you called 'git remote add' from the repository folder, or from somewhere outside of it? Git clearly said that the local folder was not the repository, I would do a double verification of it.
Yes, I called git remote add from inside the repostory folder. The problem seesm to do with adding a remote origin to an existing git installation which already has an origin set.