Version synchronization problem between git local and github
ringa_lee
ringa_lee 2017-05-02 09:32:39
0
2
568

I create the project on computer A and git it to github, then I clone a copy on computer B and continue writing the project using computer B.

Question 1: I finished writing the project on B and pushed it to github, but suddenly I couldn’t use computer B and could only use computer A to write the project. Is there a version conflict here? How to solve it?

Question 2: The git I learned only uses the git protocol to push projects, so how do I use ssh to push projects?

ringa_lee
ringa_lee

ringa_lee

reply all(2)
阿神

Question 1. It doesn’t matter if your project on computer B has not been pushed to Github yet. You can continue writing the project on computer A now, and then push it to Github and resolve the conflict when computer B is available. If your project on computer B has been pushed to Github, it is even simpler. Just pull the code on Github on computer A first.

Question 2. I think you haven’t figured out what the Git protocol is, because the only HTTP and SSH protocols commonly used on Github are the HTTP and SSH protocols, and there is no Git protocol. Since you have used Github, you don’t know how to push projects using the SSH protocol. Bar?

洪涛

Your code on A was not pushed to the remote in time. Manually modify the conflicts. In fact, you can treat your two computers as two people and create their own branches from the server git clone master.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template