Re: adding on branch
"Stefan Monnier" <monnier+gnu.cvs.bug/news/@flint.cs.yale.edu>
| Newsgroups | gmane.comp.version-control.cvs.bugs |
|---|---|
| Organization | Yale University |
| Message-ID | <[email protected]> |
> Adding a file on a branch *MUST* (due to the nature of the RCS file format)
> add a head revision. Since the head revision is simply a placeholder, it is
> marked dead.
Exactly: it's an implementation detail that has unexpected consequences.
I.e. a bug. People shouldn't have to know about it and it shouldn't affect
unrelated things like `import'.
Think of it this way:
1 - create a branch B
2 - import a new vendor version with a new file F (gets rev 1.1.1.1)
3 - add a new file F on branch B
now the HEAD of the trunk for file F is 1.1.1.1 (it's magical).
But if switch steps 2 and 3, you instead end up with a dead head
for file F on the trunk.
Why should the order of 2 and 3 make any difference to the user ?
Stefan
PS: Note that I'm not saying it's a bug to mark the head as dead.
The behavior as a whole exhibits a bug, but whether it's fixed by
"not marking head as dead" or by "import notices that the head is dead
and resurrects it" or some other mean doesn't matter.