The not-quite-so-open part of opensource...

I started using OpenFOAM around 2006 and felt liberated by its openness. Unlike commercial CFD codes where you moan about things and then wait for a new version to see if it gets better, here you can actually do something about it. In my case, this liberty also felt like an obligation to give back. So not long after starting with OpenFOAM, I was posting code on and sending tar files to Henry Weller (OpenCFD at that time) for incorporation in the OpenFOAM code base. This was naturally all a bit chaotic - no version control and manual code...   read more

11 Nov 2020 | copyright, GPL, OpenFOAM

Merging OpenFOAM versions in git

A question came up recently on this forum thread about how to merge the separate change histories from different OpenFOAM versions. The simplest solution is to merge with an ours strategy, which I’ll present directly. Of course, you can also question why disconnected git histories exist in the first place and immediately notice that the same type of issues will simply re-occur with future OpenFOAM-1.7.x, OpenFOAM-1.8.x, etc releases. I’ll thus also take the opportunity to explain why I think the current OpenFOAM development model is perhaps not as bad at it might first appear and might indeed be the only...   read more

24 Nov 2009 | OpenFOAM, git

OpenFOAM bits: the #includeIfPresent dictionary directive

As mentioned in the ReleaseNotes-1.6, the new #includeIfPresent directive is similar to the #include directive, but does not generate an error if the file does not exist. Initially, this may not sound particularly useful. Perhaps you haven’t really found very many uses for the normal #include directive anyway, so why would you ever want it to fail silently if the file doesn’t exist? This functionality turns out, however, to actually be quite useful. Before examining this, we should first be aware of the OpenFOAM string expansion that is implicit in the #include and in the #includeIfPresent directives. OpenFOAM String Expansion...   read more

17 Nov 2009 | OpenFOAM

Getting started with OpenFOAM and git

I have the general impression from the forum that many OpenFOAM users may not always understand how they should (or could) be using git effectively when they are working with OpenFOAM. After an initial git clone to set things up, the simplest method would be to simply use a periodic git pull to update things. However, this has a few distinct disadvantages: you have to recompile things immediately after the pull it makes it somewhat difficult to deal with any local changes These disadvantages may not seem severe, but with a few minor changes to your workflow it is easy...   read more

12 Nov 2009 | OpenFOAM, git

Keeping GridEngine configuration information in git

If indeed “imitation is the highest form of flattery”, then Edward Dale should indeed be flattered since I’ve taken his idea about Keeping Grid Engine configuration information in Subversion that I noticed thanks to Chris’ blog entry and simply used git for the backend storage. After seeing the simplicity of the solution and its usefulness, it looked to be a must have, except that I generally use git for almost everything and adding subversion to the mix would be annoying. The crux point thus seemed to be replacing (to import and update everything) with an equivalent git-load-dirs. Unfortunately, git-load-dirs...   read more

05 Nov 2009 | gridengine, git