News for hackers. Stuff that matters.
Re:Ask HN: Any C programming Postgres wizards willing to por... by anulman on Sunday July 05, 2015 @01:44PM (#9834243)
Did you consider leveraging the refdb to offer immutable primary keys?

I had been hacking together a Kyoto Tycoon-backed implementation for a project (since dropped); our design exposed the ref id to the user (e.g. 'master', 'master/mhodgson', etc) and branch/merge as necessary. This way, our primary keys remained a constant refName that pointed to the HEAD of a commit chain, each of which referenced immutable commits/trees/blobjects.

Although my days of libgit2 hacking are long past, I'm very curious if/how our design could have been improved; immutable pkeys were important for us as well.

Github: https://github.com/anulman/libgit2/tree/kyoto/src/backends/k...

Re:Ask HN: Any C programming Postgres wizards willing to por... by mhodgson on Sunday July 05, 2015 @06:12PM (#9835266)
I'm not sure I follow. Our use case required the ability to easily update blobs (in this case formatted written text) without having to rewrite history every time. I don't immutable ref ids addresses that particular requirement...
Re:Ask HN: Any C programming Postgres wizards willing to por... by anulman on Monday July 06, 2015 @12:17PM (#9840191)
Not sure they would either, though perhaps a use case for git_commit_amend [1]?

Regardless, sounds fairly implementation-specific. Think I just followed you on Twitter, happy to discuss further offline.

[1] https://libgit2.github.com/libgit2/#HEAD/group/commit/git_co...