NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: cvs better than git?





On Wed, 17 Jun 2020 at 23:23, Mayuresh <mayuresh%acm.org@localhost> wrote:
>
> On Wed, Jun 17, 2020 at 03:42:44PM +0530, Mayuresh wrote:
> > For pkgsrc I prefer the git mirror, as I don't have to push anything
> > anyway and a few hours of latency doesn't matter to me.
>
> Don't know whether it's relevant to say on this thread. May be it is.
>
> When I use pkgsrc git mirror, after every few days I get this error when I
> pull: "fatal: refusing to merge unrelated histories"

It isn't you.

This is a problem with the script that converts the repo from CVS (be it HG or GIT).  For some reason, from time to time, commit history gets a complete rewrite.

For instance, note the forced update in:

$ git fetch origin
...
From https://github.com/netbsd/src
 + 453a77af0964...27f1c0b47855 netbsd-9                    -> origin/netbsd-9  (forced update)
...
$ git status
On branch netbsd-9
Your branch and 'origin/netbsd-9' have diverged,
and have 269997 and 270259 different commits each, respectively.
...

Here's the first two commits in my local tree:

commit 4b1f1e65097e3f03b15cd9fa0e331ce221ed0a24
Author: mrg <mrg%NetBSD.org@localhost>
Date:   Mon Jul 13 16:18:25 1992 +0000
 
    4.4BSD-Lite2
 
commit e81d63576b2e46ab90da7d75fa155ea57ee4d32e
Author: srcmastr <srcmastr>
Date:   Mon Jul 13 16:18:24 1992 +0000
 
    initial empty check-in

and here's the same two commits from origin/netbsd-9:

commit a50e92ee94fef5ef9c87e87efc192c0a3f75f06e
Author: mrg <mrg%NetBSD.org@localhost>
Date:   Mon Jul 13 16:18:25 1992 +0000
 
    4.4BSD-Lite2
 
commit e81d63576b2e46ab90da7d75fa155ea57ee4d32e
Author: srcmastr <srcmastr>
Date:   Mon Jul 13 16:18:24 1992 +0000
 
    initial empty check-in

notice how the checksum for the second commit - an event that happened in 1992 - changed.  That shouldn't happen, I suspect something unstable about the process.

Very annoying.


> I do not know what *I* am doing wrong that leads to this. I do not even
> change anything, leave alone branch or commit.
>
> I do not know what is the `correct' way to fix this.
>
> I do the simple. Delete pkgsrc and start over with a fresh checkout again.
>
> Mayuresh


Home | Main Index | Thread Index | Old Index