How do I move my local Git repository to a remote Git repository

后端 未结 8 1628

I have various Git projects that are on my local machine. I have a server that I would like to use as my remote Git Repository. How do I move my local Git Repositories (Pro

8条回答
  •  日久生厌
    2020-12-07 09:29

    If you want a normal (eg: not bare) repository, just copy it. There is nothing special that needs to be done.

    If you want to use a bare repository on the server, just initialize it on the server, add it as a remote on the "local" copy, then push to it. (git push --mirror will get everything through.)

提交回复
热议问题