ok/jj
1
0
Fork 0
forked from mirrors/jj
jj/cli
Martin von Zweigbergk 4d42604913 git_backend: write trees involved in conflict in git commit header
We haven't used custom Git commit headers for two main reasons:

1. I don't want commits created by jj to be different from any other
   commits. I don't want Git projects to get annoyed by such commit
   and reject them.

2. I've been concerned that tools don't know how to handle such
   headers, perhaps even resulting in crashes.

The first argument doesn't apply to commits with conflicts because
such commits would never be accepted by a project whether or not they
use custom commit headers. The second argument is less relevant for
conflicted commits because most tools will be confused by such commits
anyway.

Storing conflict information in commit headers means that we can
transfer them via the regular Git wire protocol. We already include
the tree objects nested inside the root-level tree, so they will also
be transferred.

So, let's start by writing the information redundantly to the commit
header and to the existing storage. That way we can roll it back if we
realize there's a problem with using commit headers.
2024-03-10 20:51:05 -07:00
..
examples cli: extract CommandError and helper functions to new module 2024-03-03 01:11:46 +09:00
src cli: make *Args::tool fields non-public, except for DiffFormatArgs 2024-03-10 20:37:44 -07:00
testing revset: ad-hoc optimization for range queries containing unwanted wanted heads 2024-02-22 23:26:29 +09:00
tests git_backend: write trees involved in conflict in git commit header 2024-03-10 20:51:05 -07:00
build.rs
Cargo.toml templater: add similarity hint to no such method/keyword errors 2024-02-28 09:03:04 +09:00
LICENSE