git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* How do you best store structured data in git repositories?
@ 2009-12-02 21:08 Sebastian Setzer
  2009-12-02 21:17 ` Avery Pennarun
  0 siblings, 1 reply; 7+ messages in thread
From: Sebastian Setzer @ 2009-12-02 21:08 UTC (permalink / raw)
  To: git

Hi,
when you design a file format to store structured data, and you want to
manage these files with git, how do you do this best?

I'd like to hear about best practices, experiences, links to discussions
on this subject, ...

Here are some of my questions:

Do you store everything in a single file and configure git to use
special diff- and merge-tools?
Do you use XML for this purpose?
Do you take care that the contents of your file is as stable as possible
when it's saved or do you let your diff tools cope with issues like
reordering, reassignment of identifiers (for example when identifiers
are offsets in the file), ...?

Do you store one object/record per file (with filename=id, for example
with GUID-s) and hope that git will not mess them up when it merges
them?

Do you store records as directories, with very small files which contain
single attributes (because records can be considered sets of
key-value-pairs and the same applies to directories)? Do you configure
git to do a scalar merge on non-text "attributes" (with special file
extensions)?

When you don't store everything in a single, binary file: Do you use git
hooks to update an index for efficient queries on your structured data?
Do you update the whole index for every change? Or do you use git hashes
to decide which segment of your index needs to be updated?

greetings,
Sebastian

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2009-12-08  7:13 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-02 21:08 How do you best store structured data in git repositories? Sebastian Setzer
2009-12-02 21:17 ` Avery Pennarun
2009-12-04  0:14   ` David Aguilar
2009-12-04  1:45     ` Avery Pennarun
2009-12-04  8:00       ` jamesmikedupont
2009-12-07 21:20     ` Sebastian Setzer
2009-12-08  7:14       ` David Aguilar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).