Reputation: 2966
At work we have a configuration application that saves user updates to a big, complicated XML-file. Each time the administrator changes anything, the config-file on disc is updated.
I am thinking about each time the admin saves, a new revision should be created in a revision system. I think "local file"-SCM would be prefered, having to install extra products and getting communication up and running would be an un-needed installation step. Neither would concurrency be needed, since our config application is single user (at a time).
My best bet is the traditional gnu-RCS. But perhaps there are other options worth considering.
(My boss would prefer options that isn't redist limiting (like GPL), but all answers are welcome. Also the product is web-based and .net, if that is relevant to your answers.)
Upvotes: 2
Views: 35
Reputation: 399979
Do you intend to make the fact that the file is revisioned visible from within the application? So that, for instance, the user can "revert to the config from two weeks ago", like a kind of super-undo? If not, why would you add SCM to track the file?
If so, the available programming libraries might impact the choice, since you're going to want to access the revision history from code. I guess most SCM systems make that possible, Git for instance has libgit2 which seems nice.
I do get a feeling that adding a full SCM for a single file might be a bit overkill in terms of maintenance and general complexity. Perhaps you should just store the file itself with some kind of counter suffix on the filename, or store a diff
between the previous version and the current one to save on space? Note: space is (quite) cheap.
Upvotes: 1