Monday, 6 November 2017

repository - git setup for local development


I had went through few Git Tutorial and Essential Training, I had basic knowledge for GIT. What I had learn from the tutorial, they teach me how to init git repository / github (as remote).


I got a question. Since GIT is Distribution repository. As I do some researches. I found that a lot of people are creating local / server repository and ask their colleague or developer check out in machine.


Is GIT possible do it without a so call "server repository". Developer B can clone the repository from Developer A. Developer B can push his code to Developer A. What I means there is no one "server / central" Github / repository. A and B their can do their push / pull update between them. Lets say suddenly Developer C come into the team, he can either get the source code from A / B master branch.


Is this concept correct? If yes, is there any tutorial / book teach how this able to setup?


I hope I make my question clear. If you need any clarify please do let me know.



Answer



Assuming that you have shell access to the other machine you can simply do


git clone @:~/somerepository

to clone the repo. To pull you do


git pull @:~/somerepository

That's it. If you don't have shell access you can also pull via http if the files if the files are distributed via web server.


No comments:

Post a Comment

Where does Skype save my contact's avatars in Linux?

I'm using Skype on Linux. Where can I find images cached by skype of my contact's avatars? Answer I wanted to get those Skype avat...