blob: 0a8bd410be7a9c52c5e7d3adb01d176cb9f4d391 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
|
'\" t
.\" Title: git-show-index
.\" Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author]
.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
.\" Date: 09/23/2022
.\" Manual: Git Manual
.\" Source: Git 2.38.0.rc1.6.g4fd6c5e444
.\" Language: English
.\"
.TH "GIT\-SHOW\-INDEX" "1" "09/23/2022" "Git 2\&.38\&.0\&.rc1\&.6\&.g4f" "Git Manual"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
git-show-index \- Show packed archive index
.SH "SYNOPSIS"
.sp
.nf
\fIgit show\-index\fR [\-\-object\-format=<hash\-algorithm>]
.fi
.sp
.SH "DESCRIPTION"
.sp
Read the \fB\&.idx\fR file for a Git packfile (created with \fBgit-pack-objects\fR(1) or \fBgit-index-pack\fR(1)) from the standard input, and dump its contents\&. The output consists of one object per line, with each line containing two or three space\-separated columns:
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
the first column is the offset in bytes of the object within the corresponding packfile
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
the second column is the object id of the object
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
if the index version is 2 or higher, the third column contains the CRC32 of the object data
.RE
.sp
The objects are output in the order in which they are found in the index file, which should be (in a correctly constructed file) sorted by object id\&.
.sp
Note that you can get more information on a packfile by calling \fBgit-verify-pack\fR(1)\&. However, as this command considers only the index file itself, it\(cqs both faster and more flexible\&.
.SH "OPTIONS"
.PP
\-\-object\-format=<hash\-algorithm>
.RS 4
Specify the given object format (hash algorithm) for the index file\&. The valid values are
\fIsha1\fR
and (if enabled)
\fIsha256\fR\&. The default is the algorithm for the current repository (set by
\fBextensions\&.objectFormat\fR), or
\fIsha1\fR
if no value is set or outside a repository\&.\&.
.sp
THIS OPTION IS EXPERIMENTAL! SHA\-256 support is experimental and still in an early stage\&. A SHA\-256 repository will in general not be able to share work with "regular" SHA\-1 repositories\&. It should be assumed that, e\&.g\&., Git internal file formats in relation to SHA\-256 repositories may change in backwards\-incompatible ways\&. Only use
\fB\-\-object\-format=sha256\fR
for testing purposes\&.
.RE
.SH "GIT"
.sp
Part of the \fBgit\fR(1) suite
|