MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Mathematica and version control systems

  • To: mathgroup at
  • Subject: [mg61740] Re: Mathematica and version control systems
  • From: albert <awnl at>
  • Date: Thu, 27 Oct 2005 06:12:01 -0400 (EDT)
  • References: <djn3g5$ilh$>
  • Sender: owner-wri-mathgroup at


> do you have any experience with managing Mathematica notebooks
> under a version control system, like cvs or subversion?

yes, it can be done, but you need to be aware that there is a lot of
information within a notebook that is not just text, like formatting
options, graphics and caching information. Many of these things change even
when you didn't change anything relevant (e.g. when youopen or close a cell)
and will cause the version control system to think there are a lot of
changes and produce many unnecessary revisions. 

There is a perl-script around, which does some cleanup on notebooks like
deleting caching information and opening or closing all cellgroups. This
helps to avoid the worst cases and you should be able to find the script
when searching the archives of this group. Anyway, even when using this
script some of the functionalities of the version control system (like
showing "line based" differences or automatically merging when there are
conflicts) don't really work in a way to be helpful for me and I have the
feeling that I waste a lot of disk-space due to saving irrelevant
differences as new revisions.

What I do at this time is to autogenerate Package files of the "relevant"
inputcells (marked as initialization cells) and put these into the version
control system along with the notebooks. That way I have a "text only"
version of the "code" which cvs can handle a lot better. Of course that adds
additionial redundancy...

if someone else has a better setup, I would also like to hear about it...


  • Prev by Date: Re: ParametricPlot3D
  • Next by Date: Why aren't nested groups? XML again.
  • Previous by thread: Re: tensor product
  • Next by thread: Why aren't nested groups? XML again.