As an enthusiastic open-source addict I use github on a regularly base to share my knowledge with the world, to explore new software tools, to enhance software with new features, to fix bugs, to collaborate with others, and above all to live the open source way!

But I also have to admit that their are some disadvantages too, from time to time the availability, well lacks availability.., you have to pay for private repositories used for testing purposes and github enterprise can't be used publically anymore..

Self-hosted git

Using your own git instance makes your software less accessible, since like the majority of the open-source software is available through github. But on the other hand, you can use as many private repositories as you want, you can protect your git server from the interweb by running it on your private network, you have control over the availability yourself, ...

You can set up your own git server quite easy, together with some frontend it's all under your own control.

Their are some all in one systems available too, like redmine, gitlab, chilliproject and many others which combines the git repo functionality with some user management system in combination with or without project management and such.

Mirroring

So I looked for some setup where I could benefit from the github.com awareness and its features as well as the advantages of having your own git instance running.

After digging around I found a mirroring solution which can be automated through for example a jenkins instance.

Once you merged the pull request successfully and you mirrored your local repo to your upstream one, you should see that the upstream pull request also has been automatically closed by your commit.

To keep your repos clean you should remove the freshly fetched branch from upstream out of your local repository

$ git remote rm USER

Owner

This whole article only works on git repositories owned by yourself or a git organization you are member of. What I'm still trying to solve is some automated way to keep some upstream github.com repository in sync with a local private git repository through a fork you made on github.com so you could create pull requests yourself to that software.

I am an open-source addict and I really want to make efforts to share features I wrote to existing upstream software by creating pull requests, but time has learned I do forget about creating them. So I should find myself a way how to keep my private local repository in sync with the forked one on github.com by mirroring. And some way I get notified about pieces of software ready to create a pull request.

Once those pull requests are merged by the upstream author they should be synchronized automatically with the fork and the private repo to keep them all in sync.

The reason why I want to automate this process is to not forget about sharing the code with the world cause I lack time, memory and resources to do so..

It's an excuse not worth an excuse and I really should make time for it! #blameingmyself