Skip to content

Commit 2fdc0cf

Browse files
Matthew Ogilviegitster
authored andcommitted
cvsserver doc: database generally can not be reproduced consistently
A regenerated git-cvsserver database is at risk of having different CVS revision numbers from an incrementally updated database. Mention this in the the documentation, and remove an erroneous statement to the contrary. Signed-off-by: Matthew Ogilvie <mmogilvi_git@miniinfo.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 12fb25d commit 2fdc0cf

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

Documentation/git-cvsserver.txt

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -182,10 +182,9 @@ Database Backend
182182
----------------
183183

184184
'git-cvsserver' uses one database per git head (i.e. CVS module) to
185-
store information about the repository for faster access. The
186-
database doesn't contain any persistent data and can be completely
187-
regenerated from the git repository at any time. The database
188-
needs to be updated (i.e. written to) after every commit.
185+
store information about the repository to maintain consistent
186+
CVS revision numbers. The database needs to be
187+
updated (i.e. written to) after every commit.
189188

190189
If the commit is done directly by using `git` (as opposed to
191190
using 'git-cvsserver') the update will need to happen on the
@@ -204,6 +203,18 @@ write so it might not be enough to grant the users using
204203
'git-cvsserver' write access to the database file without granting
205204
them write access to the directory, too.
206205

206+
The database can not be reliably regenerated in a
207+
consistent form after the branch it is tracking has changed.
208+
Example: For merged branches, 'git-cvsserver' only tracks
209+
one branch of development, and after a 'git-merge' an
210+
incrementally updated database may track a different branch
211+
than a database regenerated from scratch, causing inconsistent
212+
CVS revision numbers. `git-cvsserver` has no way of knowing which
213+
branch it would have picked if it had been run incrementally
214+
pre-merge. So if you have to fully or partially (from old
215+
backup) regenerate the database, you should be suspicious
216+
of pre-existing CVS sandboxes.
217+
207218
You can configure the database backend with the following
208219
configuration variables:
209220

0 commit comments

Comments
 (0)