Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

conq: repository does not exist. fatal: Could not read from remote repository

Tags:

git

bitbucket

I have the ssh keys added in Bitbucket. If I do ssh -T [email protected] he says I'm logged in. But when I do a git push/pull I get the following message

conq: repository does not exist.
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

My cat .git/config outputs:

[core]
    repositoryformatversion = 0
    filemode = true
    bare = false
    logallrefupdates = true
    ignorecase = true
    precomposeunicode = true
[remote "origin"]
    url = [email protected]:myUserName/myGitRepo.git
    fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
    remote = origin
    merge = refs/heads/master
[remote "heroku"]
    url = [email protected]:herokuUrl.git
    fetch = +refs/heads/*:refs/remotes/heroku/*
[branch "somebranch"]
    remote = origin
    merge = refs/heads/somebranch

if I do:

git remote -v  

prints out:

heroku  [email protected]:herokuUrl.git (fetch)
heroku  [email protected]:herokuUrl.git (push)
origin  [email protected]:myUserName/myRepo.git (fetch)
origin  [email protected]:myUserName/myRepo.git (push)
like image 433
tvieira Avatar asked Jul 21 '14 22:07

tvieira


2 Answers

I got the same message, and I had to remove my user id from the path.... So instead of:

url = [email protected]:myUserName/myGitRepo.git

What worked was:

url = [email protected]:myGitRepo.git
like image 82
brain Avatar answered Sep 27 '22 19:09

brain


This error is because you renamed on bitbucket. First you check:

git remote -v origin [email protected]:OldName/wp_tanhoangminhgroup.com.vn.git

then you must change the path under new name

git remote set-url [email protected]:NewName/wp_tanhoangminhgroup.com.vn.git
like image 31
Sanji Avatar answered Sep 27 '22 20:09

Sanji