Blame


1 a954aa0a 2021-06-22 stsp <!DOCTYPE html>
2 a954aa0a 2021-06-22 stsp <html>
3 63657f42 2022-09-07 stsp <head>
4 63657f42 2022-09-07 stsp <meta charset="utf-8"/>
5 63657f42 2022-09-07 stsp <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
6 63657f42 2022-09-07 stsp <link rel="stylesheet" href="mandoc.css" type="text/css" media="all"/>
7 63657f42 2022-09-07 stsp <title>GOTADMIN(1)</title>
8 63657f42 2022-09-07 stsp </head>
9 a954aa0a 2021-06-22 stsp <!-- This is an automatically generated file. Do not edit.
10 a954aa0a 2021-06-22 stsp Copyright (c) 2021 Stefan Sperling
11 a954aa0a 2021-06-22 stsp
12 a954aa0a 2021-06-22 stsp Permission to use, copy, modify, and distribute this software for any
13 a954aa0a 2021-06-22 stsp purpose with or without fee is hereby granted, provided that the above
14 a954aa0a 2021-06-22 stsp copyright notice and this permission notice appear in all copies.
15 a954aa0a 2021-06-22 stsp
16 a954aa0a 2021-06-22 stsp THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
17 a954aa0a 2021-06-22 stsp WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
18 a954aa0a 2021-06-22 stsp MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
19 a954aa0a 2021-06-22 stsp ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
20 a954aa0a 2021-06-22 stsp WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
21 a954aa0a 2021-06-22 stsp ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
22 a954aa0a 2021-06-22 stsp OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
23 a954aa0a 2021-06-22 stsp -->
24 a954aa0a 2021-06-22 stsp <body>
25 63657f42 2022-09-07 stsp <div class="head" role="doc-pageheader" aria-label="Manual header
26 63657f42 2022-09-07 stsp line"><span class="head-ltitle">GOTADMIN(1)</span>
27 63657f42 2022-09-07 stsp <span class="head-vol">General Commands Manual</span>
28 63657f42 2022-09-07 stsp <span class="head-rtitle">GOTADMIN(1)</span></div>
29 63657f42 2022-09-07 stsp <main class="manual-text">
30 a954aa0a 2021-06-22 stsp <section class="Sh">
31 63657f42 2022-09-07 stsp <h2 class="Sh" id="NAME"><a class="permalink" href="#NAME">NAME</a></h2>
32 63657f42 2022-09-07 stsp <p class="Pp"><code class="Nm">gotadmin</code> &#x2014;
33 63657f42 2022-09-07 stsp <span class="Nd" role="doc-subtitle">Game of Trees repository
34 63657f42 2022-09-07 stsp administration</span></p>
35 a954aa0a 2021-06-22 stsp </section>
36 a954aa0a 2021-06-22 stsp <section class="Sh">
37 63657f42 2022-09-07 stsp <h2 class="Sh" id="SYNOPSIS"><a class="permalink" href="#SYNOPSIS">SYNOPSIS</a></h2>
38 a954aa0a 2021-06-22 stsp <table class="Nm">
39 a954aa0a 2021-06-22 stsp <tr>
40 a954aa0a 2021-06-22 stsp <td><code class="Nm">gotadmin</code></td>
41 742bb3a1 2022-10-24 stsp <td>[<code class="Fl">-hV</code>] <var class="Ar">command</var>
42 a954aa0a 2021-06-22 stsp [<var class="Ar">arg ...</var>]</td>
43 a954aa0a 2021-06-22 stsp </tr>
44 a954aa0a 2021-06-22 stsp </table>
45 a954aa0a 2021-06-22 stsp </section>
46 a954aa0a 2021-06-22 stsp <section class="Sh">
47 63657f42 2022-09-07 stsp <h2 class="Sh" id="DESCRIPTION"><a class="permalink" href="#DESCRIPTION">DESCRIPTION</a></h2>
48 a954aa0a 2021-06-22 stsp <p class="Pp"><code class="Nm">gotadmin</code> is the repository maintenance
49 376d4d52 2022-07-04 stsp tool for the <a class="Xr" aria-label="got, section 1">got(1)</a> version
50 376d4d52 2022-07-04 stsp control system.</p>
51 376d4d52 2022-07-04 stsp <p class="Pp"><a class="Xr" aria-label="got, section 1">got(1)</a> stores the
52 376d4d52 2022-07-04 stsp history of tracked files in a Git repository, as used by the Git version
53 376d4d52 2022-07-04 stsp control system. <code class="Nm">gotadmin</code> provides commands for
54 376d4d52 2022-07-04 stsp inspecting and manipulating the on-disk state of Git repositories. The
55 376d4d52 2022-07-04 stsp repository format is described in <a class="Xr" aria-label="git-repository,
56 376d4d52 2022-07-04 stsp section 5">git-repository(5)</a>.</p>
57 a954aa0a 2021-06-22 stsp <p class="Pp"><code class="Nm">gotadmin</code> provides global and
58 a954aa0a 2021-06-22 stsp command-specific options. Global options must precede the command name, and
59 a954aa0a 2021-06-22 stsp are as follows:</p>
60 a954aa0a 2021-06-22 stsp <dl class="Bl-tag">
61 a954aa0a 2021-06-22 stsp <dt id="h"><a class="permalink" href="#h"><code class="Fl">-h</code></a></dt>
62 a954aa0a 2021-06-22 stsp <dd>Display usage information and exit immediately.</dd>
63 a954aa0a 2021-06-22 stsp <dt id="V"><a class="permalink" href="#V"><code class="Fl">-V</code></a>,
64 a954aa0a 2021-06-22 stsp <code class="Fl">--version</code></dt>
65 a954aa0a 2021-06-22 stsp <dd>Display program version and exit immediately.</dd>
66 a954aa0a 2021-06-22 stsp </dl>
67 a954aa0a 2021-06-22 stsp <p class="Pp">The commands for <code class="Nm">gotadmin</code> are as
68 a954aa0a 2021-06-22 stsp follows:</p>
69 a954aa0a 2021-06-22 stsp <dl class="Bl-tag">
70 51683866 2022-07-14 stsp <dt id="init"><a class="permalink" href="#init"><code class="Cm">init</code></a>
71 3cde8558 2022-09-23 stsp [<code class="Fl">-b</code> <var class="Ar">branch</var>]
72 51683866 2022-07-14 stsp <var class="Ar">repository-path</var></dt>
73 51683866 2022-07-14 stsp <dd>Create a new empty repository at the specified
74 51683866 2022-07-14 stsp <var class="Ar">repository-path</var>.
75 51683866 2022-07-14 stsp <p class="Pp">After <code class="Cm">gotadmin init</code>, the
76 51683866 2022-07-14 stsp <code class="Cm">got import</code> command must be used to populate the
77 51683866 2022-07-14 stsp empty repository before <code class="Cm">got checkout</code> can be
78 51683866 2022-07-14 stsp used.</p>
79 3cde8558 2022-09-23 stsp <p class="Pp">The options for <code class="Cm">gotadmin init</code> are as
80 3cde8558 2022-09-23 stsp follows:</p>
81 3cde8558 2022-09-23 stsp <dl class="Bl-tag">
82 3cde8558 2022-09-23 stsp <dt id="b"><a class="permalink" href="#b"><code class="Fl">-b</code></a>
83 3cde8558 2022-09-23 stsp <var class="Ar">branch</var></dt>
84 3cde8558 2022-09-23 stsp <dd>Make the repository's HEAD reference point to the specified
85 3cde8558 2022-09-23 stsp <var class="Ar">branch</var> instead of the default branch
86 3cde8558 2022-09-23 stsp &#x201C;main&#x201D;.</dd>
87 3cde8558 2022-09-23 stsp </dl>
88 51683866 2022-07-14 stsp </dd>
89 a954aa0a 2021-06-22 stsp <dt id="info"><a class="permalink" href="#info"><code class="Cm">info</code></a>
90 a954aa0a 2021-06-22 stsp [<code class="Fl">-r</code> <var class="Ar">repository-path</var>]</dt>
91 a954aa0a 2021-06-22 stsp <dd>Display information about a repository. This includes some configuration
92 376d4d52 2022-07-04 stsp settings from <a class="Xr" aria-label="got.conf, section
93 376d4d52 2022-07-04 stsp 5">got.conf(5)</a>, and the number of objects stored in the repository, in
94 376d4d52 2022-07-04 stsp packed or loose form, as well as the current on-disk size of these
95 376d4d52 2022-07-04 stsp objects.
96 a954aa0a 2021-06-22 stsp <p class="Pp">The options for <code class="Cm">gotadmin info</code> are as
97 a954aa0a 2021-06-22 stsp follows:</p>
98 a954aa0a 2021-06-22 stsp <dl class="Bl-tag">
99 a954aa0a 2021-06-22 stsp <dt id="r"><a class="permalink" href="#r"><code class="Fl">-r</code></a>
100 a954aa0a 2021-06-22 stsp <var class="Ar">repository-path</var></dt>
101 a954aa0a 2021-06-22 stsp <dd>Use the repository at the specified path. If not specified, assume the
102 46043f6f 2021-11-23 stsp repository is located at or above the current working directory. If
103 376d4d52 2022-07-04 stsp this directory is a <a class="Xr" aria-label="got, section
104 376d4d52 2022-07-04 stsp 1">got(1)</a> work tree, use the repository path associated with this
105 376d4d52 2022-07-04 stsp work tree.</dd>
106 a954aa0a 2021-06-22 stsp </dl>
107 a954aa0a 2021-06-22 stsp </dd>
108 a954aa0a 2021-06-22 stsp <dt id="pack"><a class="permalink" href="#pack"><code class="Cm">pack</code></a>
109 f6a6fa94 2023-02-22 stsp [<code class="Fl">-aDq</code>] [<code class="Fl">-r</code>
110 a954aa0a 2021-06-22 stsp <var class="Ar">repository-path</var>] [<code class="Fl">-x</code>
111 63657f42 2022-09-07 stsp <var class="Ar">reference</var>] [<var class="Ar">reference ...</var>]</dt>
112 a954aa0a 2021-06-22 stsp <dd>Generate a new pack file and a corresponding pack file index. By default,
113 a954aa0a 2021-06-22 stsp add any loose objects which are reachable via any references to the
114 a954aa0a 2021-06-22 stsp generated pack file.
115 a954aa0a 2021-06-22 stsp <p class="Pp">If one or more <var class="Ar">reference</var> arguments is
116 a954aa0a 2021-06-22 stsp specified, only add objects which are reachable via the specified
117 a954aa0a 2021-06-22 stsp references. Each <var class="Ar">reference</var> argument may either
118 a954aa0a 2021-06-22 stsp specify a specific reference or a reference namespace, in which case all
119 a954aa0a 2021-06-22 stsp references within this namespace will be used.</p>
120 a954aa0a 2021-06-22 stsp <p class="Pp"><code class="Cm">gotadmin pack</code> always ignores
121 a954aa0a 2021-06-22 stsp references in the <span class="Pa">refs/got/</span> namespace,
122 a954aa0a 2021-06-22 stsp effectively treating such references as if they did not refer to any
123 a954aa0a 2021-06-22 stsp objects.</p>
124 a954aa0a 2021-06-22 stsp <p class="Pp">The options for <code class="Cm">gotadmin pack</code> are as
125 a954aa0a 2021-06-22 stsp follows:</p>
126 a954aa0a 2021-06-22 stsp <dl class="Bl-tag">
127 a954aa0a 2021-06-22 stsp <dt id="a"><a class="permalink" href="#a"><code class="Fl">-a</code></a></dt>
128 a954aa0a 2021-06-22 stsp <dd>Add objects to the generated pack file even if they are already packed
129 a954aa0a 2021-06-22 stsp in a different pack file. Unless this option is specified, only loose
130 a954aa0a 2021-06-22 stsp objects will be added.</dd>
131 f6a6fa94 2023-02-22 stsp <dt id="D"><a class="permalink" href="#D"><code class="Fl">-D</code></a></dt>
132 f6a6fa94 2023-02-22 stsp <dd>Force the use of ref-delta representation for deltified objects. If
133 f6a6fa94 2023-02-22 stsp this option is not specified, offset-deltas will be used to represent
134 f6a6fa94 2023-02-22 stsp deltified objects.</dd>
135 63657f42 2022-09-07 stsp <dt id="q"><a class="permalink" href="#q"><code class="Fl">-q</code></a></dt>
136 63657f42 2022-09-07 stsp <dd>Suppress progress reporting output.</dd>
137 a954aa0a 2021-06-22 stsp <dt id="r~2"><a class="permalink" href="#r~2"><code class="Fl">-r</code></a>
138 a954aa0a 2021-06-22 stsp <var class="Ar">repository-path</var></dt>
139 a954aa0a 2021-06-22 stsp <dd>Use the repository at the specified path. If not specified, assume the
140 46043f6f 2021-11-23 stsp repository is located at or above the current working directory. If
141 376d4d52 2022-07-04 stsp this directory is a <a class="Xr" aria-label="got, section
142 376d4d52 2022-07-04 stsp 1">got(1)</a> work tree, use the repository path associated with this
143 376d4d52 2022-07-04 stsp work tree.</dd>
144 a954aa0a 2021-06-22 stsp <dt id="x"><a class="permalink" href="#x"><code class="Fl">-x</code></a>
145 a954aa0a 2021-06-22 stsp <var class="Ar">reference</var></dt>
146 a954aa0a 2021-06-22 stsp <dd>Exclude objects reachable via the specified
147 a954aa0a 2021-06-22 stsp <var class="Ar">reference</var> from the pack file. The
148 a954aa0a 2021-06-22 stsp <var class="Ar">reference</var> argument may either specify a specific
149 a954aa0a 2021-06-22 stsp reference or a reference namespace, in which case all references
150 a954aa0a 2021-06-22 stsp within this namespace will be excluded. The <code class="Fl">-x</code>
151 a954aa0a 2021-06-22 stsp option may be specified multiple times to build a list of references
152 a954aa0a 2021-06-22 stsp to exclude.
153 a954aa0a 2021-06-22 stsp <p class="Pp">Exclusion takes precedence over inclusion. If a reference
154 a954aa0a 2021-06-22 stsp appears in both the included and excluded lists, it will be
155 a954aa0a 2021-06-22 stsp excluded.</p>
156 a954aa0a 2021-06-22 stsp </dd>
157 a954aa0a 2021-06-22 stsp </dl>
158 a954aa0a 2021-06-22 stsp </dd>
159 63b69821 2021-10-16 stsp <dt id="ix"><a class="permalink" href="#indexpack"><code class="Cm" id="indexpack">indexpack</code></a>
160 a954aa0a 2021-06-22 stsp <var class="Ar">packfile-path</var></dt>
161 63b69821 2021-10-16 stsp <dd>
162 63b69821 2021-10-16 stsp <div class="Bd Bd-indent"><code class="Li">(alias:
163 46043f6f 2021-11-23 stsp <code class="Cm">ix</code>)</code></div>
164 46043f6f 2021-11-23 stsp Create a pack index for the pack file at
165 a954aa0a 2021-06-22 stsp <var class="Ar">packfile-path</var>.
166 a954aa0a 2021-06-22 stsp <p class="Pp">A pack index is required for using the corresponding pack file
167 376d4d52 2022-07-04 stsp with <a class="Xr" aria-label="got, section 1">got(1)</a>. Usually, a
168 376d4d52 2022-07-04 stsp pack index will be created by commands such as <code class="Cm">gotadmin
169 376d4d52 2022-07-04 stsp pack</code> or <code class="Cm">got fetch</code> as part of regular
170 376d4d52 2022-07-04 stsp operation. The <code class="Cm">gotadmin indexpack</code> command may be
171 376d4d52 2022-07-04 stsp used to recover from a corrupt or missing index. A given pack file will
172 376d4d52 2022-07-04 stsp always yield the same bit-identical index.</p>
173 a954aa0a 2021-06-22 stsp <p class="Pp">The provided <var class="Ar">packfile-path</var> must be
174 a954aa0a 2021-06-22 stsp located within the <span class="Pa">objects/pack/</span> directory of
175 a954aa0a 2021-06-22 stsp the repository and should end in <span class="Pa">.pack</span>. The
176 a954aa0a 2021-06-22 stsp filename of the corresponding pack index is equivalent, except that it
177 a954aa0a 2021-06-22 stsp ends in <span class="Pa">.idx</span>.</p>
178 a954aa0a 2021-06-22 stsp </dd>
179 63b69821 2021-10-16 stsp <dt id="ls"><a class="permalink" href="#listpack"><code class="Cm" id="listpack">listpack</code></a>
180 63657f42 2022-09-07 stsp [<code class="Fl">-hs</code>] <var class="Ar">packfile-path</var></dt>
181 63b69821 2021-10-16 stsp <dd>
182 63b69821 2021-10-16 stsp <div class="Bd Bd-indent"><code class="Li">(alias:
183 46043f6f 2021-11-23 stsp <code class="Cm">ls</code>)</code></div>
184 46043f6f 2021-11-23 stsp List the contents of the pack file at <var class="Ar">packfile-path</var>.
185 a954aa0a 2021-06-22 stsp <p class="Pp">Each object contained in the pack file will be displayed on a
186 a954aa0a 2021-06-22 stsp single line. The information shown includes the object ID, object type,
187 a954aa0a 2021-06-22 stsp object offset, and object size.</p>
188 b078d5c4 2022-03-23 stsp <p class="Pp">If a packed object is deltified against another object, the
189 a954aa0a 2021-06-22 stsp delta base will be shown as well. For offset deltas, the delta base is
190 a954aa0a 2021-06-22 stsp identified via an offset into the pack file. For reference deltas, the
191 a954aa0a 2021-06-22 stsp delta base is identified via an object ID.</p>
192 a954aa0a 2021-06-22 stsp <p class="Pp">The provided <var class="Ar">packfile-path</var> must be
193 a954aa0a 2021-06-22 stsp located within the <span class="Pa">objects/pack/</span> directory of
194 b078d5c4 2022-03-23 stsp the repository and should end in <span class="Pa">.pack</span>. The
195 b078d5c4 2022-03-23 stsp corresponding pack index must exist and can be created with
196 b078d5c4 2022-03-23 stsp <code class="Cm">gotadmin indexpack</code> if it is missing.</p>
197 a954aa0a 2021-06-22 stsp <p class="Pp">The options for <code class="Cm">gotadmin listpack</code> are
198 a954aa0a 2021-06-22 stsp as follows:</p>
199 a954aa0a 2021-06-22 stsp <dl class="Bl-tag">
200 a954aa0a 2021-06-22 stsp <dt id="h~2"><a class="permalink" href="#h~2"><code class="Fl">-h</code></a></dt>
201 a954aa0a 2021-06-22 stsp <dd>Show object sizes in human-readable form.</dd>
202 a954aa0a 2021-06-22 stsp <dt id="s"><a class="permalink" href="#s"><code class="Fl">-s</code></a></dt>
203 a954aa0a 2021-06-22 stsp <dd>Display statistics about the pack file after listing objects. This
204 a954aa0a 2021-06-22 stsp includes the total number of objects stored in the pack file and a
205 a954aa0a 2021-06-22 stsp break-down of the number of objects per object type.</dd>
206 a954aa0a 2021-06-22 stsp </dl>
207 a954aa0a 2021-06-22 stsp </dd>
208 63b69821 2021-10-16 stsp <dt id="cl"><a class="permalink" href="#cleanup"><code class="Cm" id="cleanup">cleanup</code></a>
209 63657f42 2022-09-07 stsp [<code class="Fl">-anpq</code>] [<code class="Fl">-r</code>
210 63657f42 2022-09-07 stsp <var class="Ar">repository-path</var>]</dt>
211 63b69821 2021-10-16 stsp <dd>
212 63b69821 2021-10-16 stsp <div class="Bd Bd-indent"><code class="Li">(alias:
213 46043f6f 2021-11-23 stsp <code class="Cm">cl</code>)</code></div>
214 46043f6f 2021-11-23 stsp Purge unreferenced loose objects from the repository and display the amount
215 46043f6f 2021-11-23 stsp of disk space which has been freed as a result.
216 16cd1323 2021-07-26 stsp <p class="Pp">Unreferenced objects are present in the repository but cannot
217 16cd1323 2021-07-26 stsp be reached via any reference in the entire <span class="Pa">refs/</span>
218 16cd1323 2021-07-26 stsp namespace.</p>
219 16cd1323 2021-07-26 stsp <p class="Pp">Loose objects are stored as individual files beneath the
220 16cd1323 2021-07-26 stsp repository's <span class="Pa">objects/</span> directory, spread across
221 16cd1323 2021-07-26 stsp 256 sub-directories named after the 256 possible hexadecimal values of
222 16cd1323 2021-07-26 stsp the first byte of an object identifier.</p>
223 16cd1323 2021-07-26 stsp <p class="Pp">Packed objects stored in pack files under
224 16cd1323 2021-07-26 stsp <span class="Pa">objects/pack/</span> will not be purged. However, if
225 16cd1323 2021-07-26 stsp redundant copies of packed objects exist in loose form, such redundant
226 16cd1323 2021-07-26 stsp copies will be purged.</p>
227 16cd1323 2021-07-26 stsp <p class="Pp">Objects will usually become unreferenced as a result of
228 16cd1323 2021-07-26 stsp deleting branches or tags with <code class="Cm">got branch -d</code> or
229 16cd1323 2021-07-26 stsp <code class="Cm">got tag -d</code>. Deleting arbitrary references with
230 16cd1323 2021-07-26 stsp <code class="Cm">got ref -d</code> may also leave unreferenced objects
231 16cd1323 2021-07-26 stsp behind.</p>
232 16cd1323 2021-07-26 stsp <p class="Pp">In order to determine the set of objects which are referenced,
233 16cd1323 2021-07-26 stsp search all references for commit objects and tag objects, and traverse
234 16cd1323 2021-07-26 stsp the corresponding tree object hierarchies. Any loose object IDs not
235 16cd1323 2021-07-26 stsp encountered during this search are unreferenced and thus subject to
236 16cd1323 2021-07-26 stsp removal. Display the number of commits which have been searched to
237 16cd1323 2021-07-26 stsp indicate progress.</p>
238 16cd1323 2021-07-26 stsp <p class="Pp">References in the <span class="Pa">refs/got</span> namespace
239 16cd1323 2021-07-26 stsp may prevent objects from being purged. This includes references in the
240 16cd1323 2021-07-26 stsp <span class="Pa">refs/got/worktree</span> namespace created by
241 16cd1323 2021-07-26 stsp <code class="Cm">got checkout</code> and <code class="Cm">got
242 16cd1323 2021-07-26 stsp update</code>, as well as references in the
243 16cd1323 2021-07-26 stsp <span class="Pa">refs/got/backup</span> namespace created by
244 16cd1323 2021-07-26 stsp <code class="Cm">got rebase</code> and <code class="Cm">got
245 16cd1323 2021-07-26 stsp histedit</code>. <code class="Cm">gotadmin cleanup</code> will only
246 16cd1323 2021-07-26 stsp purge corresponding objects once such references have been deleted with
247 16cd1323 2021-07-26 stsp <code class="Cm">got ref -d</code>.</p>
248 16cd1323 2021-07-26 stsp <p class="Pp">Some Git repositories contain pack index files which lack a
249 16cd1323 2021-07-26 stsp corresponding pack file, which is an inconsistent repository state. In
250 16cd1323 2021-07-26 stsp such cases, <code class="Cm">gotadmin cleanup -p -n</code> will display
251 b078d5c4 2022-03-23 stsp a list of affected pack index files. Whenever possible, the missing pack
252 16cd1323 2021-07-26 stsp files should be restored. If restoring missing pack files is not
253 b078d5c4 2022-03-23 stsp possible, then affected pack index files can be removed with
254 16cd1323 2021-07-26 stsp <code class="Cm">gotadmin cleanup -p</code>.</p>
255 16cd1323 2021-07-26 stsp <p class="Pp">The &#x201C;preciousObjects&#x201D; Git extension is intended
256 16cd1323 2021-07-26 stsp to prevent the removal of objects from a repository.
257 16cd1323 2021-07-26 stsp <code class="Cm">gotadmin cleanup</code> will refuse to operate on
258 16cd1323 2021-07-26 stsp repositories where this extension is active.</p>
259 16cd1323 2021-07-26 stsp <p class="Pp">The options for <code class="Cm">gotadmin cleanup</code> are
260 16cd1323 2021-07-26 stsp as follows:</p>
261 16cd1323 2021-07-26 stsp <dl class="Bl-tag">
262 def5be4a 2021-08-31 stsp <dt id="a~2"><a class="permalink" href="#a~2"><code class="Fl">-a</code></a></dt>
263 def5be4a 2021-08-31 stsp <dd>Delete all loose objects. By default, objects which are newer than an
264 def5be4a 2021-08-31 stsp implementation-defined modification timestamp are kept on disk to
265 def5be4a 2021-08-31 stsp prevent race conditions with other commands that add new objects to
266 def5be4a 2021-08-31 stsp the repository while <code class="Cm">gotadmin cleanup</code> is
267 def5be4a 2021-08-31 stsp running.</dd>
268 16cd1323 2021-07-26 stsp <dt id="n"><a class="permalink" href="#n"><code class="Fl">-n</code></a></dt>
269 16cd1323 2021-07-26 stsp <dd>Display the usual progress output and summary information but do not
270 16cd1323 2021-07-26 stsp actually remove any files from disk.</dd>
271 63657f42 2022-09-07 stsp <dt id="p"><a class="permalink" href="#p"><code class="Fl">-p</code></a></dt>
272 63657f42 2022-09-07 stsp <dd>Instead of purging unreferenced loose objects, remove any pack index
273 63657f42 2022-09-07 stsp files which do not have a corresponding pack file.</dd>
274 63657f42 2022-09-07 stsp <dt id="q~2"><a class="permalink" href="#q~2"><code class="Fl">-q</code></a></dt>
275 63657f42 2022-09-07 stsp <dd>Suppress progress reporting and disk space summary output.</dd>
276 16cd1323 2021-07-26 stsp <dt id="r~3"><a class="permalink" href="#r~3"><code class="Fl">-r</code></a>
277 16cd1323 2021-07-26 stsp <var class="Ar">repository-path</var></dt>
278 16cd1323 2021-07-26 stsp <dd>Use the repository at the specified path. If not specified, assume the
279 46043f6f 2021-11-23 stsp repository is located at or above the current working directory. If
280 376d4d52 2022-07-04 stsp this directory is a <a class="Xr" aria-label="got, section
281 376d4d52 2022-07-04 stsp 1">got(1)</a> work tree, use the repository path associated with this
282 376d4d52 2022-07-04 stsp work tree.</dd>
283 16cd1323 2021-07-26 stsp </dl>
284 16cd1323 2021-07-26 stsp </dd>
285 a954aa0a 2021-06-22 stsp </dl>
286 a954aa0a 2021-06-22 stsp </section>
287 a954aa0a 2021-06-22 stsp <section class="Sh">
288 63657f42 2022-09-07 stsp <h2 class="Sh" id="EXIT_STATUS"><a class="permalink" href="#EXIT_STATUS">EXIT
289 63657f42 2022-09-07 stsp STATUS</a></h2>
290 a954aa0a 2021-06-22 stsp <p class="Pp">The <code class="Nm">gotadmin</code> utility exits&#x00A0;0 on
291 a954aa0a 2021-06-22 stsp success, and&#x00A0;&gt;0 if an error occurs.</p>
292 a954aa0a 2021-06-22 stsp </section>
293 a954aa0a 2021-06-22 stsp <section class="Sh">
294 63657f42 2022-09-07 stsp <h2 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE
295 63657f42 2022-09-07 stsp ALSO</a></h2>
296 376d4d52 2022-07-04 stsp <p class="Pp"><a class="Xr" aria-label="got, section 1">got(1)</a>,
297 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="tog, section 1">tog(1)</a>,
298 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="git-repository, section 5">git-repository(5)</a>,
299 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="got.conf, section 5">got.conf(5)</a></p>
300 a954aa0a 2021-06-22 stsp </section>
301 a954aa0a 2021-06-22 stsp <section class="Sh">
302 63657f42 2022-09-07 stsp <h2 class="Sh" id="AUTHORS"><a class="permalink" href="#AUTHORS">AUTHORS</a></h2>
303 51683866 2022-07-14 stsp <p class="Pp"><span class="An">Christian Weisgerber</span>
304 51683866 2022-07-14 stsp &lt;<a class="Mt" href="mailto:naddy@openbsd.org">naddy@openbsd.org</a>&gt;
305 a954aa0a 2021-06-22 stsp <br/>
306 51683866 2022-07-14 stsp <span class="An">Josh Rickmar</span>
307 51683866 2022-07-14 stsp &lt;<a class="Mt" href="mailto:jrick@zettaport.com">jrick@zettaport.com</a>&gt;
308 51683866 2022-07-14 stsp <br/>
309 51683866 2022-07-14 stsp <span class="An">Klemens Nanni</span>
310 51683866 2022-07-14 stsp &lt;<a class="Mt" href="mailto:kn@openbsd.org">kn@openbsd.org</a>&gt;
311 51683866 2022-07-14 stsp <br/>
312 a954aa0a 2021-06-22 stsp <span class="An">Ori Bernstein</span>
313 51683866 2022-07-14 stsp &lt;<a class="Mt" href="mailto:ori@openbsd.org">ori@openbsd.org</a>&gt;
314 51683866 2022-07-14 stsp <br/>
315 51683866 2022-07-14 stsp <span class="An">Stefan Sperling</span>
316 51683866 2022-07-14 stsp &lt;<a class="Mt" href="mailto:stsp@openbsd.org">stsp@openbsd.org</a>&gt;
317 51683866 2022-07-14 stsp <br/>
318 51683866 2022-07-14 stsp <span class="An">Tracey Emery</span>
319 51683866 2022-07-14 stsp &lt;<a class="Mt" href="mailto:tracey@traceyemery.net">tracey@traceyemery.net</a>&gt;</p>
320 a954aa0a 2021-06-22 stsp </section>
321 16cd1323 2021-07-26 stsp <section class="Sh">
322 63657f42 2022-09-07 stsp <h2 class="Sh" id="CAVEATS"><a class="permalink" href="#CAVEATS">CAVEATS</a></h2>
323 16cd1323 2021-07-26 stsp <p class="Pp"><code class="Nm">gotadmin</code> is a work-in-progress and some
324 16cd1323 2021-07-26 stsp features remain to be implemented.</p>
325 376d4d52 2022-07-04 stsp <p class="Pp">At present, the user has to fall back on
326 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="git, section 1">git(1)</a> to perform some tasks.
327 376d4d52 2022-07-04 stsp In particular:</p>
328 16cd1323 2021-07-26 stsp <ul class="Bl-bullet">
329 16cd1323 2021-07-26 stsp <li>Removing redundant or unreferenced packed objects requires
330 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="git-gc, section 1">git-gc(1)</a> and perhaps
331 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="git-repack, section 1">git-repack(1)</a>.</li>
332 16cd1323 2021-07-26 stsp <li>Exporting data from repositories requires
333 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="git-fast-export, section
334 376d4d52 2022-07-04 stsp 1">git-fast-export(1)</a>.</li>
335 16cd1323 2021-07-26 stsp <li>Importing data into repositories requires
336 376d4d52 2022-07-04 stsp <a class="Xr" aria-label="git-fast-import, section
337 376d4d52 2022-07-04 stsp 1">git-fast-import(1)</a>.</li>
338 16cd1323 2021-07-26 stsp </ul>
339 16cd1323 2021-07-26 stsp </section>
340 16cd1323 2021-07-26 stsp <section class="Sh">
341 63657f42 2022-09-07 stsp <h2 class="Sh" id="BUGS"><a class="permalink" href="#BUGS">BUGS</a></h2>
342 16cd1323 2021-07-26 stsp <p class="Pp">Disk space savings reported by <code class="Cm">gotadmin
343 16cd1323 2021-07-26 stsp cleanup</code> will be misleading if the repository contains object files
344 16cd1323 2021-07-26 stsp that were hard-linked from another repository. Such hard-links will be
345 376d4d52 2022-07-04 stsp created by certain <a class="Xr" aria-label="git, section 1">git(1)</a>
346 376d4d52 2022-07-04 stsp commands. By itself, <a class="Xr" aria-label="got, section 1">got(1)</a>
347 376d4d52 2022-07-04 stsp will never create hard-linked object files.</p>
348 16cd1323 2021-07-26 stsp </section>
349 63657f42 2022-09-07 stsp </main>
350 63657f42 2022-09-07 stsp <div class="foot" role="doc-pagefooter" aria-label="Manual footer
351 f6a6fa94 2023-02-22 stsp line"><span class="foot-left"></span><span class="foot-date">February 22,
352 47f19dd5 2023-01-17 stsp 2023</span> <span class="foot-os">OpenBSD 7.2</span></div>
353 a954aa0a 2021-06-22 stsp </body>
354 a954aa0a 2021-06-22 stsp </html>