Hacker News new | past | comments | ask | show | jobs | submit login

>Are you genuinely signing off on the history?

No, you are signing off current state of the repository. Otherwise it would be possible (not trivial, but possible) to take signed commit and apply it on different history, which could create a security loophole.

Your view on commit is a logical set of changes. Git's view is state of the repository. The set of changes between revisions, which is useful for developer to see more than the whole state, is computed on the fly.

>I was just saying we need something else to use for identifying commits.

The commit message?




> Your view on commit is a logical set of changes. Git's view is state of the repository.

No, my view of a commit is not a logical set of changes. It's everything that would be in my worktree if I checked out the commit. Which is neither merely the changes from the previous commit(s), nor the entire history leading to the current commit.


But git already has this object, it’s called a tree and each commit has a unique tree associated with it. The commits are the object that carries history and metadata on top of the trees. Is your objection that the commit metadata is associated to the commit and not the tree?


To a first approximation, yes, I think that captures the general idea.

But I don't think it's literally as simple as just taking the commit metadata and slapping it onto the tree objects.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: