Re: git repo port issues?
- Reply: Jamie Landeg-Jones : "Re: git repo port issues?"
- In reply to: Brooks Davis : "Re: git repo port issues?"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 04 Jan 2024 09:35:39 UTC
On Wed, 3 Jan 2024 23:32:27 +0000 Brooks Davis <brooks@freebsd.org> wrote: > On Wed, Jan 03, 2024 at 03:09:15PM -0800, Bakul Shah wrote: > > On Jan 3, 2024, at 11:22???AM, Brooks Davis <brooks@freebsd.org> wrote: > > > > > > Nothing about dates is centralized in git, but some server side checks > > > could be implemented on CommitDate. IMO we should require that > > > CommitDate be >= the previous one and less than "now". > > > > Given that git commit objects form a DAG, I don't see how you can > > impose linearity. > > Check each commit in a push to ensure that its CommitDate is newer than > its first parent's CommitDate (you could check them all, but as a > project we're mostly linear). Seems like a pretty trivial property to > enforce. > > -- Brooks Or create database (key-value store would be sufficient) storing commit order (like r* of svn) and commit hash. I'm still not certain whether commit order or commit hash should be the "key". Possibly store hash as the key fisrt and store assigned MONOTONIC order as value, then, add the just-stored order as key and hash as value in another database would be neeed. If the database can contain 2 value for 1 key, it would be suitable for you to store the assigned time in UTC as "when it is committed to FreeBSD master repo". Just a thought. Regards. -- Tomoaki AOKI <junchoon@dec.sakura.ne.jp>