I'm creating a webframework hosted on a public Github repository.
The same framework is hosted on a server with some customization.

So how can I manage those two states developement and production?

My current approach is pretty expensive: On the Server I pull the code from the repo, get merge conflicts because of the customization, have to merge it, and sometimes have to add my customization again.
I don't want my customization to be public, so a different branch for production is no option.

  • 3
    I'm voting to close this question as off-topic because it is about workflow handling different versions (public vs private, closed), not specific to open source at all. – vonbrand Jan 31 '16 at 18:43
  • In my opinion this question is open source specific, because you won't have this problem when developing proprietary software. – 0xAffe Jan 31 '16 at 19:44
  • 2
    With propietary software you have the same problem, released branch(es) versus development branches, where (for whatever reason) not everybody has access to latest developments. – vonbrand Jan 31 '16 at 20:44
  • 1
    @vonbrand There is nothing off topic about this question. The OP is asking how to incorporate a mix of open and proprietary software into a single workflow. This is a common challenge faced by many people working in corporate environments or who build businesses on open source foundations. Further, this question does not ask about any "off-site resources", which is the current reason given for the question being closed and is clearly an inappropriate application of that rule. I wish I knew how to vote to reopen the question. – Michael Hogan Feb 5 '16 at 9:27
  • @MichaelHogan the traditional mix is separate open source and proprietary stuff developed in-house, not intertwine them. – vonbrand Feb 5 '16 at 14:06

Try reconsidering the architecture of your application. Can you modify the open framework to allow you to implement the private changes using a plugin or theme?

Many open source applications take advantage of the flexibility provided by plugins and themes. The Atom text editor and the Wordpress website framework are two examples of open source software with strong plugin and theme communities. Wordpress demonstrates how closed features can be built to extend an open framework.

You can step beyond plugins and themes by introducing an API or breaking a large open source project into a collection of smaller projects. The Linux and UNIX communities often favor smaller, focused tools.

Don't forget to check the licenses of the open source frameworks you choose and make sure they allow the flexibility you need.

| improve this answer | |
  • I accepted this answer, because I think it leads me to the right way. I outsourced all the content which can be customized to seperate files. This way I can checkin new code from my development machine and check it out on my production machine. The customization persists, because there are no changes on those files. Of course there will still be problems when I have to change the structure of the customization files. But this won't happen very often. – 0xAffe Feb 5 '16 at 9:47
  • @0xAffe Check out what DHH has done with Ruby on Rails. I may go back and add summary information to my answer, but the highlight is that their open source framework, Ruby on Rails, was extracted from their proprietary application, Basecamp. DHH designed Rails so that he could continue improving Basecamp without releasing proprietary code. Rails went on to become one of the most popular web development frameworks of the past fifteen years. – Michael Hogan Feb 5 '16 at 14:59
  • @0xAffe Thank you, and glad it helped – Michael Hogan Feb 5 '16 at 15:00
  • All this is needed only if he has any plans to redistribute his custom production code to someone else. Otherwise, if it is just for the private use, is there really any need for adding an extra layer of plugin-based architecture? – Prahlad Yeri Feb 7 '16 at 9:05

You can have a private branch on your development machine(s). Yes, it becomes a hassle to keep it up to date. On the other hand, gitosis handles private branches, public and private repositories, and doesn't need a whole lot to set up.

| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.