Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Hi i cloned a local repository on another server http://localipaddress/git/project . It created an empty repository. When i tried to pull from the repository, it gave me an error

Your configuration specifies to merge with the ref 'master' from the remote but no such ref was detected.

On push i get the following message

error:Cannot access url "http://localipaddress/git/project" , return code 22 . Fatal git-http-push failed

What could have been wrong.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

The issue is resolved. In mycase , it just worked out using the following url while cloning

http://username:password@localipaddress/git/project ,
instead of http://localipaddress/git/project.

May be some issue with the way username/pwds are handled by the repsoitory.

also in the .git/config file, need to check whether the following details are present

[remote "origin"]
    url = http://username:password@localipaddress/git/project 
    fetch = +refs/heads/*:refs/remotes/origin/*

[branch "master"]
    remote = origin
    merge = refs/heads/master
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.