Version control (SVN) and managing sample data?

90 views Asked by At

We've developed a desktop application that collects measurements from a scientific instrument.

The measurements are stored in a single SQLite database file and some associated binary data files.

The app ships with some sample data, so I've put the pre-populated files under revision control (we use Subversion/Ankh/Tortoise).

But now my co-worker is complaining that every time he does an Update on the project, any changes he may have made to the database get clobbered by the sample data database in the repository.

How can we manage this so:

  1. When we do a release, we can ensure the proper sample data from the repository is included.

  2. Between releases, our working copies of the database are not overwritten when we update our code from the repository.

1

There are 1 answers

0
manojlds On

Look at having data in the form of SQL scripts in your repo, managed through a database change management tool like dbdeploy

Version control is great with text files and not so with binaries. Anything that can be represented as text should be done so. And anything that can be generated through a build process - the dlls, jars, etc. and the db, should be artifacts of your build process and maintained outside your repo.