Reputation: 5001
Github is great! But, if you don't have access to Github or any other git server, and can't set up your own git server, then you're limited to using a central git repository on a Local Area Network (LAN) folder to collaborate with other developers on the same LAN.
There are two popular git workflows as far I know:
Forking and Pulling vs Pushing has some useful info.
I found lots of help online on how to get a 'Shared repository' model working (see this branching model). The model is pretty easy to implement on a LAN and doesn't require a git server. However, I am led to believe there is no control over the central repository with this workflow model.
It seems to me that the 'Forking and Pulling' model will give me control over the central repository, and allow me to freely share the repository with anyone. I wouldn't have to worry about them pushing bad code to the central repository.
However, there isn't much out there on how to implement a fork and pull workflow without a git server. I imagine the issue can be split into the following sub-questions:
How can one implement the fork and pull model without Github or a git server?
Upvotes: 0
Views: 135
Reputation: 311645
How does a fellow developer submit a pull request to the central repository owner?
If everyone has publicly accessible repositories there is the git request-pull command, which generates on stdout a pull request suitable for emailing to someone.
If people don't have publicly accessible repositories, then email and git format-patch
are probably how you would solve things.
How does the central repository owner see the pull request,
By reading email.
fetch the code from that developer's repository
Either pulling it from the remote repository, or using git am
to apply patches that were generated with git format-patch
.
test
That seems unrelated to git. Presumably your project has a test suite that you can run.
and edit it to meet the required standard before pushing the feature to the public repository?
Just edit things locally after applying the patch(es), or ask the submitter to reformat things to meet your standards and resubmit.
The Linux Kernel uses email for managing patches; you can read about it here.
Upvotes: 1