zoukankan      html  css  js  c++  java
  • Changing a remote's URL

    参考: https://help.github.com/articles/changing-a-remote-s-url/
    The git remote set-url command changes an existing remote repository URL.

    The git remote set-url command takes two arguments:
    An existing remote name. For example, origin or upstream are two common choices.
    A new URL for the remote.

    List your existing remotes in order to get the name of the remote you want to change.

    git remote -v
    origin git@github.com:USERNAME/REPOSITORY.git (fetch)
    origin git@github.com:USERNAME/REPOSITORY.git (push)
    Change your remote's URL from SSH to HTTPS with the git remote set-url command.

    git remote set-url origin https://github.com/USERNAME/OTHERREPOSITORY.git
    Verify that the remote URL has changed.

    git remote -v
    # Verify new remote URL
    origin https://github.com/USERNAME/OTHERREPOSITORY.git (fetch)
    origin https://github.com/USERNAME/OTHERREPOSITORY.git (push)

  • 相关阅读:
    第二十一天作业
    第二十天:继承
    第二十天作业
    第十六天
    第十九天作业
    day53
    day52
    day51
    day50
    day44
  • 原文地址:https://www.cnblogs.com/qike/p/5461649.html
Copyright © 2011-2022 走看看