diff options
| author | Justin Tobler <jltobler@gmail.com> | 2025-02-04 18:41:46 -0600 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2025-02-05 09:32:01 -0800 |
| commit | c6d896bcfde1cfb626c8bc25c71d00662ef7f22c (patch) | |
| tree | b0bc95c13a7c4ae5e1a8965ecf22b10a2368cfb7 /Documentation | |
| parent | bc204b742735ae06f65bb20291c95985c9633b7f (diff) | |
| download | git-c6d896bcfde1cfb626c8bc25c71d00662ef7f22c.tar.xz | |
rev-list: add print-info action to print missing object path
Missing objects identified through git-rev-list(1) can be printed by
setting the `--missing=print` option. Additional information about the
missing object, such as its path and type, may be present in its
containing object.
Add the `print-info` missing action for the `--missing` option that,
when set, prints additional insight about the missing object inferred
from its containing object. Each line of output for a missing object is
in the form: `?<oid> [<token>=<value>]...`. The `<token>=<value>` pairs
containing additional information are separated from each other by a SP.
The value is encoded in a token specific fashion, but SP or LF contained
in value are always expected to be represented in such a way that the
resulting encoded value does not have either of these two problematic
bytes. This format is kept generic so it can be extended in the future
to support additional information.
For now, only a missing object path info is implemented. It follows the
form `path=<path>` and specifies the full path to the object from the
top-level tree. A path containing SP or special characters is enclosed
in double-quotes in the C style as needed. In a subsequent commit,
missing object type info will also be added.
Signed-off-by: Justin Tobler <jltobler@gmail.com>
Acked-by: Christian Couder <christian.couder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation')
| -rw-r--r-- | Documentation/rev-list-options.txt | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Documentation/rev-list-options.txt b/Documentation/rev-list-options.txt index 459e5a02f5..0bea9d4ad3 100644 --- a/Documentation/rev-list-options.txt +++ b/Documentation/rev-list-options.txt @@ -1024,6 +1024,22 @@ Unexpected missing objects will raise an error. The form '--missing=print' is like 'allow-any', but will also print a list of the missing objects. Object IDs are prefixed with a ``?'' character. + +The form '--missing=print-info' is like 'print', but will also print additional +information about the missing object inferred from its containing object. The +information is all printed on the same line with the missing object ID in the +form: `?<oid> [<token>=<value>]...`. The `<token>=<value>` pairs containing +additional information are separated from each other by a SP. The value is +encoded in a token specific fashion, but SP or LF contained in value are always +expected to be represented in such a way that the resulting encoded value does +not have either of these two problematic bytes. Each `<token>=<value>` may be +one of the following: ++ +-- +* The `path=<path>` shows the path of the missing object inferred from a + containing object. A path containing SP or special characters is enclosed in + double-quotes in the C style as needed. +-- ++ If some tips passed to the traversal are missing, they will be considered as missing too, and the traversal will ignore them. In case we cannot get their Object ID though, an error will be raised. |
