github no address associated with name

后端 未结 3 1820
你的背包
你的背包 2021-02-09 10:23

I kept having problem with github these days, i created a new repository on github, then from local machine I tried to push my code to github:

git remote add origin g         


        
相关标签:
3条回答
  • 2021-02-09 10:27

    Look:

    fatal: remote origin already exists
    

    You already have a remote named origin, and it's still using the old, invalid URL. Open up .git/config and change the URL for the origin remote, or use the set-url subcommand for git remote:

    $ git remote set-url origin git@github.com:tmi/logger.git
    
    0 讨论(0)
  • 2021-02-09 10:27

    I had the no address associated with name problem and after searching it was a DNS problem. The DNS simply was wrong on the machine and it could not find the IP address of the remote git repository.

    0 讨论(0)
  • 2021-02-09 10:30

    How would the error

    ssh git -v
    OpenSSH_4.6p1, OpenSSL 0.9.8e 23 Fed 2007
    ssh: git: no address associated with name
    

    be related to

    fatal: remote origin already exists?
    

    Also couldn't that problem be solved by

    git remote add someothername git@github.com:tmi/logger.git
    
    0 讨论(0)
提交回复
热议问题