.NET as Open Source

Microsoft is open sourcing some .NET components. This follows steps taken by Microsoft in this direction in the past few years (some may say baby steps with heavy marketing).

I still remember a time when you had Open Source projects on one side and Microsoft on the other side considering Open Source a “cancer that attaches itself in an intellectual property sense to everything it touches”.

Having worked for years with Open Source software in on different platforms, I didn’t immediately embrace the .NET platform which basically belonged to the Evil Empire. But at some point in my career, I was forced to start working with C#. Even though there were many aspects which I liked, the lack of openness was always an issue for me.

A little bit more than a year ago, I started working on a project where I use the Mono Compiler Service, NRefactory and the Orchard CMS. Even though I had been programming in C# for a few years already, this is about the time when I started writing more articles related to .NET.

So hearing that more .NET component are being released under the MIT license is good news.

Of course, it doesn’t mean that .NET is now a completely open platform. First not all of it is open source and this is (still) a one way street where Microsoft releases something and it then lives a life of its own without taking contributions back to the pieces of software distributed by Microsoft. So saying that Microsoft is open sourcing .NET is not completely true, saying that .NET is now open source is kind of misleading, but it doesn’t mean that this news has to be discarded as some pure publicity stunt from Redmond.

On the other hand, Microsoft has slowly started understanding that we’re in a new kind of market and developer communities play a major role. So going alone the way they did in the past will fail in the long term. The only way to attract more developers and make sure that you will not become obsolete 10 years from now is to open up and create an expanding community based on your products. So of course, every small step in opening .NET will be publicized as a huge step and Microsoft going Open Source but even if you get rid of all the marketing fog, I feel it’s still good news. It shows that the Open Source community has actually reached an important milestone in altering the way our industry works.

Xamarin and the Mono project it’s for sure a very welcome evolution. Just like the availability of Roslyn does open new perspectives for NRefactory and projects using NRefactory, the free availability of this code will hopefully allow many improvements in Mono and also help make its development even faster. And if it means that one day it makes Mono obsolete, as long as there is a multi-platform open alternative, I don’t see why it would be a bad thing.

So I’ll definitely have a look at the .NET Core CLR and the open source ASP.NET components on my Mac and on my Linux machines. And I do sure hope that this open sourcing of some .NET components will be followed by more and will lead to some great new projects. Of course Microsoft has an agenda of its own and open sourcing .NET components is not done just to make the world a better place. But does it really matter ? I’m always ready to complain when Microsoft is using its market strength to push crappy software to the world but whenever a change comes from their side and goes in the right direction, I feel we need to give them a chance.

Of course it’s great to do the right thing because it’s the right to do but doing the right thing because you expect to earn money out of it or just get some positive publicity is still better than not doing it or doing something wrong. So instead of complaining as some immediately did, let’s have a look at it and try to find out what new possibilities this opens.

SourceForge or GitHub: repositories for open source projects

There are two main types of open source repositories:

  1. SourceForge and similar
  2. GitHub and similar

The difference is mainly that SourceForge is mostly appropriate for project which want to have a centralized approach to open source development. On the other hand, GitHub is all about forking and making it easy to create forks and merge the changes between forks of a project. In the past two years many open source projects moved from SourceForge or Google Code to GitHub. My Open Source projects are now all also hosted on GitHub.

How forking is handled or accepted depends mainly on the goal you have by making a project open source. If you want to maximize the involvement of the community and are ready to loose some control on the software, forking is a great thing. Anybody can fork the project basically creating a new branch based on some existing project version and correct errors or implement new features. This changes can of course be merged back in the original branch or any other branch. On the other hand, one can decide to keep a fork alive by merging bug fixes and features from the original branch or from another fork. Without forking, one has to register as a developer in the project and his changes need to be checked and approved. So without forking, it makes it much easier for someone to just provide a bug fix or a new feature for an existing piece of software to the community. That’s why support for easy forking maximizes the involvement of others by making it easy to participate.

On the other hand, the disadvantage of this approach is that you have less control on the software and that you risk having many different non-compatible versions of the software in the field. There is not a single version anymore on which all developers work on but an original version maintained by the original contributors and potentially multiple forks which are only there for a short time and are not always well maintained. It can also happen that a fork goes in a direction which is not accepted by the original contributors and keeps living forever. In this case it could also happen that users decide they like the fork better and that the original contributor completely looses control on the software. This might be good for the community but as an original contributor you might see it in a different way.

When looking at the projects hosted on SourceForge and GitHub you also clearly see another difference: Many projects on SourceForge provide downloadable and installable packages to be used by normal users e.g. VLC Player, multiple Bittorrent clients, 7-zip, Notepad++, Filezilla… So project targeting end users. These are software my mother might be using. She of course doesn’t care much for the source code. She just needs to have a stable package available.

Projects on Github are different. The largest projects there are things like Homebrew, Ruby on Rails, Android, PHP and other frameworks. I doubt my mother would use any of these projects. But for me or other developers these projects tend to be very interesting. And there I do not need any installer. I actually do not really need a ZIP file either. It’s all about getting access to the code.

So SourceForge and GitHub basically address two different needs and two different philosophies. There is room for both of them and we will probably continue seeing projects moving to GitHub and new projects created in SourceForge. Regarding Google code which I used for a time, I frankly do not see any reason to use it for my projects at all since it’s kind of something in the middle and I do not really see for which kind of projects it’d be better than SourceForge and GitHub.