简体   繁体   中英

Is it a good workflow with Git with no central repository?

We are working on a project in a 3 people team. We don't have yet a separate machine to set up a Git central server so we have to get along without it. We will have the machine in a few days so I treat the curent workflow more like an experiment. So now we do like this:

1) every member is creating a git repository on his computer simply like this:

 git init

2) every member makes his repository readable by others like this:

in .git directory:

touch git-daemon-export-ok

And then:

git daemon &

3) every member sends address of his repository to other members and every member imports it like this:

git remote add aa git://xxx.xxx.xxx.xxx/home/username/code

Now when the initial setup is done our workflow looks like this:

We checkout to the dev branch on our local repository to do the work. When we're done, we pull other members' master branches into our repository:

git pull --rebase aa master
git pull --rebase ab master
...

Finally we squash commits from our dev branch if necessary and merge them with our local master. From now on other members will be able to download these commits form our computer into their masters.

What do you think about it?

#

I should add that this is happening in the company and we are not allowed to use Github or something like this here. Our software is going to be open source but we have to follow strict security policy.

I believe if the team is self disciplined there shouldn't be any problem, but definitely treat this aa temporary solution, because if the team increase will be much harder to avoid problems. Btw maybe think about github private repository. They work like a charm.

Seems rather a convoluted solution to me. So why not just use a hosted service temporarily, and move to your own Git server when it arrives?

Obviously, GitHub is the 800-pound gorilla in the room here, but I personally use BitBucket in a professional capacity because unlike GitHub, it offers free private repositories (but limited to five users).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM