Blame


1 5c860e29 2018-03-12 stsp .\"
2 5c860e29 2018-03-12 stsp .\" Copyright (c) 2017 Martin Pieuchot
3 5aa81393 2020-01-06 stsp .\" Copyright (c) 2018, 2019, 2020 Stefan Sperling
4 5c860e29 2018-03-12 stsp .\"
5 5c860e29 2018-03-12 stsp .\" Permission to use, copy, modify, and distribute this software for any
6 5c860e29 2018-03-12 stsp .\" purpose with or without fee is hereby granted, provided that the above
7 5c860e29 2018-03-12 stsp .\" copyright notice and this permission notice appear in all copies.
8 5c860e29 2018-03-12 stsp .\"
9 5c860e29 2018-03-12 stsp .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 5c860e29 2018-03-12 stsp .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 5c860e29 2018-03-12 stsp .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 5c860e29 2018-03-12 stsp .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 5c860e29 2018-03-12 stsp .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 5c860e29 2018-03-12 stsp .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 5c860e29 2018-03-12 stsp .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16 5c860e29 2018-03-12 stsp .\"
17 5c860e29 2018-03-12 stsp .Dd $Mdocdate$
18 5c860e29 2018-03-12 stsp .Dt GOT 1
19 5c860e29 2018-03-12 stsp .Os
20 5c860e29 2018-03-12 stsp .Sh NAME
21 5c860e29 2018-03-12 stsp .Nm got
22 8e13c46f 2019-08-05 stsp .Nd Game of Trees
23 5c860e29 2018-03-12 stsp .Sh SYNOPSIS
24 0bb8a95e 2018-03-12 stsp .Nm
25 5c860e29 2018-03-12 stsp .Ar command
26 1b6b95a8 2018-03-12 stsp .Op Fl h
27 5c860e29 2018-03-12 stsp .Op Ar arg ...
28 5c860e29 2018-03-12 stsp .Sh DESCRIPTION
29 5c860e29 2018-03-12 stsp .Nm
30 4dfb2f0f 2019-03-26 stsp is a version control system which stores the history of tracked files
31 4dfb2f0f 2019-03-26 stsp in a Git repository, as used by the Git version control system.
32 285dc8a4 2018-03-13 stsp This repository format is described in
33 5e5560e1 2018-08-01 stsp .Xr git-repository 5 .
34 285dc8a4 2018-03-13 stsp .Pp
35 4129c201 2018-03-13 stsp .Nm
36 4129c201 2018-03-13 stsp is a
37 ae73e26f 2019-03-26 stsp .Dq distributed
38 4129c201 2018-03-13 stsp version control system because every copy of a repository is writeable.
39 4129c201 2018-03-13 stsp Modifications made to files can be synchronized between repositories
40 97925469 2018-03-17 stsp at any time.
41 4129c201 2018-03-13 stsp .Pp
42 285dc8a4 2018-03-13 stsp Files managed by
43 285dc8a4 2018-03-13 stsp .Nm
44 4129c201 2018-03-13 stsp must be checked out from the repository for modification.
45 285dc8a4 2018-03-13 stsp Checked out files are stored in a
46 285dc8a4 2018-03-13 stsp .Em work tree
47 c5867b47 2018-03-13 stsp which can be placed at an arbitrary directory in the filesystem hierarchy.
48 fb2921d0 2019-03-26 stsp The on-disk format of this work tree is described in
49 285dc8a4 2018-03-13 stsp .Xr got-worktree 5 .
50 285dc8a4 2018-03-13 stsp .Pp
51 285dc8a4 2018-03-13 stsp .Nm
52 285dc8a4 2018-03-13 stsp provides global and command-specific options.
53 bc3056e3 2019-08-18 stsp Global options must precede the command name, and are as follows:
54 1b6b95a8 2018-03-12 stsp .Bl -tag -width tenletters
55 1b6b95a8 2018-03-12 stsp .It Fl h
56 fef8a0d3 2019-08-04 stsp Display usage information and exit immediately.
57 83cd27f8 2020-01-13 stsp .It Fl V, -version
58 53ccebc2 2019-07-30 stsp Display program version and exit immediately.
59 1b6b95a8 2018-03-12 stsp .El
60 1b6b95a8 2018-03-12 stsp .Pp
61 38e11793 2018-06-13 stsp The commands for
62 38e11793 2018-06-13 stsp .Nm
63 38e11793 2018-06-13 stsp are as follows:
64 0bb8a95e 2018-03-12 stsp .Bl -tag -width checkout
65 09ea71ba 2019-07-27 stsp .It Cm init Ar repository-path
66 2c7829a4 2019-06-17 stsp Create a new empty repository at the specified
67 09ea71ba 2019-07-27 stsp .Ar repository-path .
68 3ce1b845 2019-07-15 stsp .Pp
69 3ce1b845 2019-07-15 stsp After
70 3ce1b845 2019-07-15 stsp .Cm got init ,
71 3ce1b845 2019-07-15 stsp the
72 3ce1b845 2019-07-15 stsp .Cm got import
73 3ce1b845 2019-07-15 stsp command must be used to populate the empty repository before
74 3ce1b845 2019-07-15 stsp .Cm got checkout
75 3ce1b845 2019-07-15 stsp can be used.
76 dfc23429 2019-08-11 stsp .It Cm import Oo Fl b Ar branch Oc Oo Fl m Ar message Oc Oo Fl r Ar repository-path Oc Oo Fl I Ar pattern Oc Ar directory
77 3ce1b845 2019-07-15 stsp Create an initial commit in a repository from the file hierarchy
78 3ce1b845 2019-07-15 stsp within the specified
79 3ce1b845 2019-07-15 stsp .Ar directory .
80 3ce1b845 2019-07-15 stsp The created commit will not have any parent commits, i.e. it will be a
81 3ce1b845 2019-07-15 stsp root commit.
82 3ce1b845 2019-07-15 stsp Also create a new reference which provides a branch name for the newly
83 3ce1b845 2019-07-15 stsp created commit.
84 21a44f98 2019-07-15 stsp Show the path of each imported file to indicate progress.
85 3ce1b845 2019-07-15 stsp .Pp
86 21a44f98 2019-07-15 stsp The
87 21a44f98 2019-07-15 stsp .Cm got import
88 21a44f98 2019-07-15 stsp command requires the
89 21a44f98 2019-07-15 stsp .Ev GOT_AUTHOR
90 aba9c984 2019-09-08 stsp environment variable to be set,
91 257add31 2020-09-09 stsp unless an author has been configured in
92 257add31 2020-09-09 stsp .Xr got.conf 5
93 257add31 2020-09-09 stsp or Git's
94 aba9c984 2019-09-08 stsp .Dv user.name
95 aba9c984 2019-09-08 stsp and
96 709ae9eb 2019-09-08 stsp .Dv user.email
97 709ae9eb 2019-09-08 stsp configuration settings can be obtained from the repository's
98 aba9c984 2019-09-08 stsp .Pa .git/config
99 c9956ddf 2019-09-08 stsp file or from Git's global
100 c9956ddf 2019-09-08 stsp .Pa ~/.gitconfig
101 c9956ddf 2019-09-08 stsp configuration file.
102 3ce1b845 2019-07-15 stsp .Pp
103 3ce1b845 2019-07-15 stsp The options for
104 3ce1b845 2019-07-15 stsp .Cm got import
105 3ce1b845 2019-07-15 stsp are as follows:
106 3ce1b845 2019-07-15 stsp .Bl -tag -width Ds
107 3ce1b845 2019-07-15 stsp .It Fl b Ar branch
108 3ce1b845 2019-07-15 stsp Create the specified
109 3ce1b845 2019-07-15 stsp .Ar branch
110 3ce1b845 2019-07-15 stsp instead of creating the default branch
111 5d67f40d 2019-11-08 stsp .Dq main .
112 3ce1b845 2019-07-15 stsp Use of this option is required if the
113 5d67f40d 2019-11-08 stsp .Dq main
114 3ce1b845 2019-07-15 stsp branch already exists.
115 3ce1b845 2019-07-15 stsp .It Fl m Ar message
116 3ce1b845 2019-07-15 stsp Use the specified log message when creating the new commit.
117 3ce1b845 2019-07-15 stsp Without the
118 3ce1b845 2019-07-15 stsp .Fl m
119 3ce1b845 2019-07-15 stsp option,
120 3ce1b845 2019-07-15 stsp .Cm got import
121 3ce1b845 2019-07-15 stsp opens a temporary file in an editor where a log message can be written.
122 3ce1b845 2019-07-15 stsp .It Fl r Ar repository-path
123 3ce1b845 2019-07-15 stsp Use the repository at the specified path.
124 3ce1b845 2019-07-15 stsp If not specified, assume the repository is located at or above the current
125 3ce1b845 2019-07-15 stsp working directory.
126 3ce1b845 2019-07-15 stsp .It Fl I Ar pattern
127 3ce1b845 2019-07-15 stsp Ignore files or directories with a name which matches the specified
128 3ce1b845 2019-07-15 stsp .Ar pattern .
129 3ce1b845 2019-07-15 stsp This option may be specified multiple times to build a list of ignore patterns.
130 3ce1b845 2019-07-15 stsp The
131 3ce1b845 2019-07-15 stsp .Ar pattern
132 3ce1b845 2019-07-15 stsp follows the globbing rules documented in
133 3ce1b845 2019-07-15 stsp .Xr glob 7 .
134 3ce1b845 2019-07-15 stsp .El
135 bc26cce8 2019-08-04 stsp .It Cm im
136 bc26cce8 2019-08-04 stsp Short alias for
137 bc26cce8 2019-08-04 stsp .Cm import .
138 0e4002ca 2020-03-21 stsp .It Cm clone Oo Fl a Oc Oo Fl b Ar branch Oc Oo Fl l Oc Oo Fl m Oc Oo Fl q Oc Oo Fl v Oc Oo Fl R Ar reference Oc Ar repository-URL Op Ar directory
139 2ab43947 2020-03-18 stsp Clone a Git repository at the specified
140 2ab43947 2020-03-18 stsp .Ar repository-URL
141 2ab43947 2020-03-18 stsp into the specified
142 3493b628 2020-03-20 stsp .Ar directory .
143 2ab43947 2020-03-18 stsp If no
144 3493b628 2020-03-20 stsp .Ar directory
145 2ab43947 2020-03-18 stsp is specified the directory name will be derived from the name of the
146 2ab43947 2020-03-18 stsp cloned repository.
147 2ab43947 2020-03-18 stsp .Cm got clone
148 2ab43947 2020-03-18 stsp will refuse to run if the
149 3493b628 2020-03-20 stsp .Ar directory
150 2ab43947 2020-03-18 stsp already exists.
151 2ab43947 2020-03-18 stsp .Pp
152 2ab43947 2020-03-18 stsp The
153 2ab43947 2020-03-18 stsp .Ar repository-URL
154 619eb6dd 2020-03-20 stsp specifies a protocol scheme, a server hostname, an optional port number
155 619eb6dd 2020-03-20 stsp separated from the hostname by a colon, and a path to the repository on
156 619eb6dd 2020-03-20 stsp the server:
157 619eb6dd 2020-03-20 stsp .Lk scheme://hostname:port/path/to/repository
158 2ab43947 2020-03-18 stsp .Pp
159 2ab43947 2020-03-18 stsp The following protocol schemes are supported:
160 2ab43947 2020-03-18 stsp .Bl -tag -width git+ssh
161 2ab43947 2020-03-18 stsp .It git
162 2ab43947 2020-03-18 stsp The Git protocol as implemented by the
163 2ab43947 2020-03-18 stsp .Xr git-daemon 1
164 2ab43947 2020-03-18 stsp server.
165 10c073e7 2020-03-20 stsp Use of this protocol is discouraged since it supports neither authentication
166 10c073e7 2020-03-20 stsp nor encryption.
167 2ab43947 2020-03-18 stsp .It git+ssh
168 2ab43947 2020-03-18 stsp The Git protocol wrapped in an authenticated and encrypted
169 2ab43947 2020-03-18 stsp .Xr ssh 1
170 2ab43947 2020-03-18 stsp tunnel.
171 2ab43947 2020-03-18 stsp With this protocol the hostname may contain an embedded username for
172 2ab43947 2020-03-18 stsp .Xr ssh 1
173 2ab43947 2020-03-18 stsp to use:
174 2ab43947 2020-03-18 stsp .Mt user@hostname
175 2ab43947 2020-03-18 stsp .It ssh
176 2ab43947 2020-03-18 stsp Short alias for git+ssh.
177 2ab43947 2020-03-18 stsp .El
178 89c3c67b 2020-03-20 stsp .Pp
179 89c3c67b 2020-03-20 stsp Objects in the cloned repository are stored in a pack file which is downloaded
180 89c3c67b 2020-03-20 stsp from the server.
181 89c3c67b 2020-03-20 stsp This pack file will then be indexed to facilitate access to the objects stored
182 89c3c67b 2020-03-20 stsp within.
183 89c3c67b 2020-03-20 stsp If any objects in the pack file are stored in deltified form, all deltas will
184 89c3c67b 2020-03-20 stsp be fully resolved in order to compute the ID of such objects.
185 89c3c67b 2020-03-20 stsp This can take some time.
186 010f7279 2020-03-20 stsp More details about the pack file format are documented in
187 010f7279 2020-03-20 stsp .Xr git-repository 5 .
188 2ab43947 2020-03-18 stsp .Pp
189 7848a0e1 2020-03-19 stsp .Cm got clone
190 7848a0e1 2020-03-19 stsp creates a remote repository entry in the
191 257add31 2020-09-09 stsp .Xr got.conf 5
192 257add31 2020-09-09 stsp and
193 7848a0e1 2020-03-19 stsp .Pa config
194 257add31 2020-09-09 stsp files of the cloned repository to store the
195 7848a0e1 2020-03-19 stsp .Ar repository-url
196 15d3c221 2021-01-05 stsp and
197 15d3c221 2021-01-05 stsp .Ar branch
198 132af4a5 2021-01-05 stsp arguments for future use by
199 7848a0e1 2020-03-19 stsp .Cm got fetch
200 fc24bb3a 2020-03-21 stsp or
201 7848a0e1 2020-03-19 stsp .Xr git-fetch 1 .
202 7848a0e1 2020-03-19 stsp .Pp
203 2ab43947 2020-03-18 stsp The options for
204 2ab43947 2020-03-18 stsp .Cm got clone
205 2ab43947 2020-03-18 stsp are as follows:
206 2ab43947 2020-03-18 stsp .Bl -tag -width Ds
207 659e7fbd 2020-03-20 stsp .It Fl a
208 1d4b192f 2020-03-21 stsp Fetch all branches from the remote repository's
209 1d4b192f 2020-03-21 stsp .Dq refs/heads/
210 1d4b192f 2020-03-21 stsp reference namespace.
211 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
212 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
213 4ba14133 2020-03-20 stsp Cannot be used together with the
214 4ba14133 2020-03-20 stsp .Fl b
215 4ba14133 2020-03-20 stsp option.
216 4ba14133 2020-03-20 stsp .It Fl b Ar branch
217 4ba14133 2020-03-20 stsp Fetch the specified
218 4ba14133 2020-03-20 stsp .Ar branch
219 1d4b192f 2020-03-21 stsp from the remote repository's
220 1d4b192f 2020-03-21 stsp .Dq refs/heads/
221 1d4b192f 2020-03-21 stsp reference namespace.
222 4ba14133 2020-03-20 stsp This option may be specified multiple times to build a list of branches
223 4ba14133 2020-03-20 stsp to fetch.
224 4ba14133 2020-03-20 stsp If the branch corresponding to the remote repository's HEAD reference is not
225 4ba14133 2020-03-20 stsp in this list, the cloned repository's HEAD reference will be set to the first
226 4ba14133 2020-03-20 stsp branch which was fetched.
227 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
228 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
229 4ba14133 2020-03-20 stsp Cannot be used together with the
230 4ba14133 2020-03-20 stsp .Fl a
231 4ba14133 2020-03-20 stsp option.
232 41b0de12 2020-03-21 stsp .It Fl l
233 a18cccf9 2020-03-21 stsp List branches and tags available for fetching from the remote repository
234 41b0de12 2020-03-21 stsp and exit immediately.
235 41b0de12 2020-03-21 stsp Cannot be used together with any of the other options except
236 41b0de12 2020-03-21 stsp .Fl v .
237 469dd726 2020-03-20 stsp .It Fl m
238 469dd726 2020-03-20 stsp Create the cloned repository as a mirror of the original repository.
239 469dd726 2020-03-20 stsp This is useful if the cloned repository will not be used to store
240 bd81cfb7 2020-04-19 stsp locally created commits.
241 469dd726 2020-03-20 stsp .Pp
242 469dd726 2020-03-20 stsp The repository's
243 257add31 2020-09-09 stsp .Xr got.conf 5
244 257add31 2020-09-09 stsp and
245 469dd726 2020-03-20 stsp .Pa config
246 257add31 2020-09-09 stsp files will be set up with the
247 469dd726 2020-03-20 stsp .Dq mirror
248 469dd726 2020-03-20 stsp option enabled, such that
249 469dd726 2020-03-20 stsp .Cm got fetch
250 469dd726 2020-03-20 stsp or
251 469dd726 2020-03-20 stsp .Xr git-fetch 1
252 bd81cfb7 2020-04-19 stsp will write incoming changes directly to branches in the
253 469dd726 2020-03-20 stsp .Dq refs/heads/
254 469dd726 2020-03-20 stsp reference namespace, rather than to branches in the
255 469dd726 2020-03-20 stsp .Dq refs/remotes/
256 469dd726 2020-03-20 stsp namespace.
257 469dd726 2020-03-20 stsp This avoids the usual requirement of having to run
258 469dd726 2020-03-20 stsp .Cm got rebase
259 469dd726 2020-03-20 stsp after
260 469dd726 2020-03-20 stsp .Cm got fetch
261 bd81cfb7 2020-04-19 stsp in order to make incoming changes appear on branches in the
262 bd81cfb7 2020-04-19 stsp .Dq refs/heads/
263 bd81cfb7 2020-04-19 stsp namespace.
264 bd81cfb7 2020-04-19 stsp But maintaining custom changes in the cloned repository becomes difficult
265 bd81cfb7 2020-04-19 stsp since such changes will be at risk of being discarded whenever incoming
266 498ef124 2020-03-21 stsp changes are fetched.
267 2ab43947 2020-03-18 stsp .It Fl q
268 2ab43947 2020-03-18 stsp Suppress progress reporting output.
269 2ab43947 2020-03-18 stsp The same option will be passed to
270 2ab43947 2020-03-18 stsp .Xr ssh 1
271 2ab43947 2020-03-18 stsp if applicable.
272 2ab43947 2020-03-18 stsp .It Fl v
273 2690194b 2020-03-21 stsp Verbose mode.
274 2690194b 2020-03-21 stsp Causes
275 2690194b 2020-03-21 stsp .Cm got clone
276 2690194b 2020-03-21 stsp to print debugging messages to standard error output.
277 2690194b 2020-03-21 stsp This option will be passed to
278 2ab43947 2020-03-18 stsp .Xr ssh 1
279 2ab43947 2020-03-18 stsp if applicable.
280 2ab43947 2020-03-18 stsp Multiple -v options increase the verbosity.
281 2ab43947 2020-03-18 stsp The maximum is 3.
282 0e4002ca 2020-03-21 stsp .It Fl R Ar reference
283 0e4002ca 2020-03-21 stsp In addition to the branches and tags that will be fetched, fetch an arbitrary
284 0e4002ca 2020-03-21 stsp .Ar reference
285 0e4002ca 2020-03-21 stsp from the remote repository's
286 0e4002ca 2020-03-21 stsp .Dq refs/
287 0e4002ca 2020-03-21 stsp namespace.
288 0e4002ca 2020-03-21 stsp This option may be specified multiple times to build a list of additional
289 0e4002ca 2020-03-21 stsp references to fetch.
290 71f12362 2020-03-21 stsp The specified
291 71f12362 2020-03-21 stsp .Ar reference
292 a18cccf9 2020-03-21 stsp may either be a path to a specific reference, or a reference namespace
293 71f12362 2020-03-21 stsp which will cause all references in this namespace to be fetched.
294 0e4002ca 2020-03-21 stsp .Pp
295 71f12362 2020-03-21 stsp Each reference will be mapped into the cloned repository's
296 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
297 0e4002ca 2020-03-21 stsp namespace, unless the
298 0e4002ca 2020-03-21 stsp .Fl m
299 0e4002ca 2020-03-21 stsp option is used to mirror references directly into the cloned repository's
300 0e4002ca 2020-03-21 stsp .Dq refs/
301 0e4002ca 2020-03-21 stsp namespace.
302 0e4002ca 2020-03-21 stsp .Pp
303 0e4002ca 2020-03-21 stsp .Cm got clone
304 0e4002ca 2020-03-21 stsp will refuse to fetch references from the remote repository's
305 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
306 0e4002ca 2020-03-21 stsp or
307 0e4002ca 2020-03-21 stsp .Dq refs/got/
308 0e4002ca 2020-03-21 stsp namespace.
309 2ab43947 2020-03-18 stsp .El
310 267fe567 2020-03-18 stsp .It Cm cl
311 267fe567 2020-03-18 stsp Short alias for
312 267fe567 2020-03-18 stsp .Cm clone .
313 4d482d9d 2020-03-21 stsp .It Cm fetch Oo Fl a Oc Oo Fl b Ar branch Oc Oo Fl d Oc Oo Fl l Oc Oo Fl r Ar repository-path Oc Oo Fl t Oc Oo Fl q Oc Oo Fl v Oc Oo Fl R Ar reference Oc Op Ar remote-repository
314 7848a0e1 2020-03-19 stsp Fetch new changes from a remote repository.
315 7848a0e1 2020-03-19 stsp If no
316 4ba14133 2020-03-20 stsp .Ar remote-repository
317 4ba14133 2020-03-20 stsp is specified,
318 7848a0e1 2020-03-19 stsp .Dq origin
319 7848a0e1 2020-03-19 stsp will be used.
320 50b0790e 2020-09-11 stsp The remote repository's URL is obtained from the corresponding entry in
321 257add31 2020-09-09 stsp .Xr got.conf 5
322 50b0790e 2020-09-11 stsp or Git's
323 7848a0e1 2020-03-19 stsp .Pa config
324 f8ab0c60 2020-03-20 stsp file of the local repository, as created by
325 7848a0e1 2020-03-19 stsp .Cm got clone .
326 7848a0e1 2020-03-19 stsp .Pp
327 89c3c67b 2020-03-20 stsp New changes will be stored in a separate pack file downloaded from the server.
328 89c3c67b 2020-03-20 stsp Optionally, separate pack files stored in the repository can be combined with
329 89c3c67b 2020-03-20 stsp .Xr git-repack 1 .
330 89c3c67b 2020-03-20 stsp .Pp
331 498ef124 2020-03-21 stsp By default, branch references in the
332 7848a0e1 2020-03-19 stsp .Dq refs/remotes/
333 498ef124 2020-03-21 stsp reference namespace will be updated to point at the newly fetched commits.
334 498ef124 2020-03-21 stsp The
335 498ef124 2020-03-21 stsp .Cm got rebase
336 bd81cfb7 2020-04-19 stsp command can then be used to make new changes visible on branches in the
337 7848a0e1 2020-03-19 stsp .Dq refs/heads/
338 bd81cfb7 2020-04-19 stsp namespace, merging incoming changes with the changes on those branches
339 bd81cfb7 2020-04-19 stsp as necessary.
340 7848a0e1 2020-03-19 stsp .Pp
341 498ef124 2020-03-21 stsp If the repository was created as a mirror with
342 498ef124 2020-03-21 stsp .Cm got clone -m
343 498ef124 2020-03-21 stsp then all branches in the
344 469dd726 2020-03-20 stsp .Dq refs/heads/
345 498ef124 2020-03-21 stsp namespace will be updated directly to match the corresponding branches in
346 498ef124 2020-03-21 stsp the remote repository.
347 175367bd 2020-03-20 stsp If those branches contained local commits, these commits will no longer be
348 175367bd 2020-03-20 stsp reachable via a reference and will therefore be at risk of being discarded
349 175367bd 2020-03-20 stsp by Git's garbage collector.
350 bd81cfb7 2020-04-19 stsp Maintaining custom changes in a mirror repository is therefore discouraged.
351 469dd726 2020-03-20 stsp .Pp
352 db6d8ad8 2020-03-21 stsp In any case, references in the
353 7848a0e1 2020-03-19 stsp .Dq refs/tags/
354 db6d8ad8 2020-03-21 stsp namespace will always be fetched and mapped directly to local references
355 db6d8ad8 2020-03-21 stsp in the same namespace.
356 7848a0e1 2020-03-19 stsp .Pp
357 7848a0e1 2020-03-19 stsp The options for
358 7848a0e1 2020-03-19 stsp .Cm got fetch
359 7848a0e1 2020-03-19 stsp are as follows:
360 7848a0e1 2020-03-19 stsp .Bl -tag -width Ds
361 659e7fbd 2020-03-20 stsp .It Fl a
362 1d4b192f 2020-03-21 stsp Fetch all branches from the remote repository's
363 1d4b192f 2020-03-21 stsp .Dq refs/heads/
364 1d4b192f 2020-03-21 stsp reference namespace.
365 0c8b29c5 2021-01-05 stsp This option can be enabled by default for specific repositories in
366 0c8b29c5 2021-01-05 stsp .Xr got.conf 5 .
367 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
368 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
369 4ba14133 2020-03-20 stsp Cannot be used together with the
370 4ba14133 2020-03-20 stsp .Fl b
371 4ba14133 2020-03-20 stsp option.
372 4ba14133 2020-03-20 stsp .It Fl b Ar branch
373 4ba14133 2020-03-20 stsp Fetch the specified
374 4ba14133 2020-03-20 stsp .Ar branch
375 1d4b192f 2020-03-21 stsp from the remote repository's
376 1d4b192f 2020-03-21 stsp .Dq refs/heads/
377 1d4b192f 2020-03-21 stsp reference namespace.
378 4ba14133 2020-03-20 stsp This option may be specified multiple times to build a list of branches
379 4ba14133 2020-03-20 stsp to fetch.
380 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
381 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
382 4ba14133 2020-03-20 stsp Cannot be used together with the
383 4ba14133 2020-03-20 stsp .Fl a
384 4ba14133 2020-03-20 stsp option.
385 f21ec2f0 2020-03-21 stsp .It Fl d
386 f21ec2f0 2020-03-21 stsp Delete branches and tags from the local repository which are no longer
387 f21ec2f0 2020-03-21 stsp present in the remote repository.
388 f21ec2f0 2020-03-21 stsp Only references are deleted.
389 239821eb 2020-03-21 stsp Any commit, tree, tag, and blob objects belonging to deleted branches or
390 f21ec2f0 2020-03-21 stsp tags remain in the repository and may be removed separately with
391 f21ec2f0 2020-03-21 stsp Git's garbage collector.
392 41b0de12 2020-03-21 stsp .It Fl l
393 41b0de12 2020-03-21 stsp List branches and tags available for fetching from the remote repository
394 41b0de12 2020-03-21 stsp and exit immediately.
395 41b0de12 2020-03-21 stsp Cannot be used together with any of the other options except
396 612392ee 2021-01-05 stsp .Fl v ,
397 612392ee 2021-01-05 stsp .Fl q ,
398 41b0de12 2020-03-21 stsp and
399 41b0de12 2020-03-21 stsp .Fl r .
400 db6d8ad8 2020-03-21 stsp .It Fl t
401 db6d8ad8 2020-03-21 stsp Allow existing references in the
402 db6d8ad8 2020-03-21 stsp .Dq refs/tags
403 db6d8ad8 2020-03-21 stsp namespace to be updated if they have changed on the server.
404 db6d8ad8 2020-03-21 stsp If not specified, only new tag references will be created.
405 7848a0e1 2020-03-19 stsp .It Fl r Ar repository-path
406 7848a0e1 2020-03-19 stsp Use the repository at the specified path.
407 7848a0e1 2020-03-19 stsp If not specified, assume the repository is located at or above the current
408 7848a0e1 2020-03-19 stsp working directory.
409 7848a0e1 2020-03-19 stsp If this directory is a
410 7848a0e1 2020-03-19 stsp .Nm
411 7848a0e1 2020-03-19 stsp work tree, use the repository path associated with this work tree.
412 7848a0e1 2020-03-19 stsp .It Fl q
413 7848a0e1 2020-03-19 stsp Suppress progress reporting output.
414 7848a0e1 2020-03-19 stsp The same option will be passed to
415 7848a0e1 2020-03-19 stsp .Xr ssh 1
416 7848a0e1 2020-03-19 stsp if applicable.
417 7848a0e1 2020-03-19 stsp .It Fl v
418 2690194b 2020-03-21 stsp Verbose mode.
419 2690194b 2020-03-21 stsp Causes
420 2690194b 2020-03-21 stsp .Cm got fetch
421 2690194b 2020-03-21 stsp to print debugging messages to standard error output.
422 7848a0e1 2020-03-19 stsp The same option will be passed to
423 7848a0e1 2020-03-19 stsp .Xr ssh 1
424 7848a0e1 2020-03-19 stsp if applicable.
425 7848a0e1 2020-03-19 stsp Multiple -v options increase the verbosity.
426 7848a0e1 2020-03-19 stsp The maximum is 3.
427 0e4002ca 2020-03-21 stsp .It Fl R Ar reference
428 0e4002ca 2020-03-21 stsp In addition to the branches and tags that will be fetched, fetch an arbitrary
429 0e4002ca 2020-03-21 stsp .Ar reference
430 0e4002ca 2020-03-21 stsp from the remote repository's
431 0e4002ca 2020-03-21 stsp .Dq refs/
432 0e4002ca 2020-03-21 stsp namespace.
433 0e4002ca 2020-03-21 stsp This option may be specified multiple times to build a list of additional
434 0e4002ca 2020-03-21 stsp references to fetch.
435 71f12362 2020-03-21 stsp The specified
436 71f12362 2020-03-21 stsp .Ar reference
437 a18cccf9 2020-03-21 stsp may either be a path to a specific reference, or a reference namespace
438 71f12362 2020-03-21 stsp which will cause all references in this namespace to be fetched.
439 0e4002ca 2020-03-21 stsp .Pp
440 0e4002ca 2020-03-21 stsp Each reference will be mapped into the local repository's
441 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
442 0e4002ca 2020-03-21 stsp namespace, unless the local repository was created as a mirror with
443 a18cccf9 2020-03-21 stsp .Cm got clone -m
444 a18cccf9 2020-03-21 stsp in which case references will be mapped directly into the local repository's
445 a18cccf9 2020-03-21 stsp .Dq refs/
446 a18cccf9 2020-03-21 stsp namespace.
447 a18cccf9 2020-03-21 stsp .Pp
448 bd81cfb7 2020-04-19 stsp Once a reference has been fetched, a branch based on it can be created with
449 0e4002ca 2020-03-21 stsp .Cm got branch
450 0e4002ca 2020-03-21 stsp if needed.
451 0e4002ca 2020-03-21 stsp .Pp
452 0e4002ca 2020-03-21 stsp .Cm got fetch
453 0e4002ca 2020-03-21 stsp will refuse to fetch references from the remote repository's
454 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
455 0e4002ca 2020-03-21 stsp or
456 0e4002ca 2020-03-21 stsp .Dq refs/got/
457 0e4002ca 2020-03-21 stsp namespace.
458 7848a0e1 2020-03-19 stsp .El
459 7848a0e1 2020-03-19 stsp .It Cm fe
460 7848a0e1 2020-03-19 stsp Short alias for
461 7848a0e1 2020-03-19 stsp .Cm fetch .
462 74daf7cb 2020-01-27 stsp .It Cm checkout Oo Fl E Oc Oo Fl b Ar branch Oc Oo Fl c Ar commit Oc Oo Fl p Ar path-prefix Oc Ar repository-path Op Ar work-tree-path
463 0bb8a95e 2018-03-12 stsp Copy files from a repository into a new work tree.
464 bb51a5b4 2020-01-13 stsp Show the status of each affected file, using the following status codes:
465 bb51a5b4 2020-01-13 stsp .Bl -column YXZ description
466 bb51a5b4 2020-01-13 stsp .It A Ta new file was added
467 bb51a5b4 2020-01-13 stsp .It E Ta file already exists in work tree's meta-data
468 bb51a5b4 2020-01-13 stsp .El
469 bb51a5b4 2020-01-13 stsp .Pp
470 5d7c1dab 2018-04-01 stsp If the
471 5d7c1dab 2018-04-01 stsp .Ar work tree path
472 c844a238 2019-02-06 stsp is not specified, either use the last component of
473 5d7c1dab 2018-04-01 stsp .Ar repository path ,
474 5d7c1dab 2018-04-01 stsp or if a
475 5d7c1dab 2018-04-01 stsp .Ar path prefix
476 c844a238 2019-02-06 stsp was specified use the last component of
477 5d7c1dab 2018-04-01 stsp .Ar path prefix .
478 38e11793 2018-06-13 stsp .Pp
479 38e11793 2018-06-13 stsp The options for
480 38e11793 2018-06-13 stsp .Cm got checkout
481 38e11793 2018-06-13 stsp are as follows:
482 38e11793 2018-06-13 stsp .Bl -tag -width Ds
483 bb51a5b4 2020-01-13 stsp .It Fl E
484 bb51a5b4 2020-01-13 stsp Proceed with the checkout operation even if the directory at
485 bb51a5b4 2020-01-13 stsp .Ar work-tree-path
486 bb51a5b4 2020-01-13 stsp is not empty.
487 bb51a5b4 2020-01-13 stsp Existing files will be left intact.
488 08573d5b 2019-05-14 stsp .It Fl b Ar branch
489 3c575567 2019-07-28 stsp Check out files from a commit on the specified
490 08573d5b 2019-05-14 stsp .Ar branch .
491 08573d5b 2019-05-14 stsp If this option is not specified, a branch resolved via the repository's HEAD
492 08573d5b 2019-05-14 stsp reference will be used.
493 8069f636 2019-01-12 stsp .It Fl c Ar commit
494 8069f636 2019-01-12 stsp Check out files from the specified
495 3c575567 2019-07-28 stsp .Ar commit
496 3c575567 2019-07-28 stsp on the selected branch.
497 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
498 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
499 0e1b0230 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
500 0e1b0230 2019-07-07 stsp automatically, provided the abbreviation is unique.
501 08573d5b 2019-05-14 stsp If this option is not specified, the most recent commit on the selected
502 08573d5b 2019-05-14 stsp branch will be used.
503 4b6c9460 2020-03-05 stsp .Pp
504 4b6c9460 2020-03-05 stsp If the specified
505 4b6c9460 2020-03-05 stsp .Ar commit
506 4b6c9460 2020-03-05 stsp is not contained in the selected branch, a different branch which contains
507 4b6c9460 2020-03-05 stsp this commit must be specified with the
508 4b6c9460 2020-03-05 stsp .Fl b
509 4b6c9460 2020-03-05 stsp option.
510 4b6c9460 2020-03-05 stsp If no such branch is known a new branch must be created for this
511 4b6c9460 2020-03-05 stsp commit with
512 4b6c9460 2020-03-05 stsp .Cm got branch
513 4b6c9460 2020-03-05 stsp before
514 4b6c9460 2020-03-05 stsp .Cm got checkout
515 4b6c9460 2020-03-05 stsp can be used.
516 4b6c9460 2020-03-05 stsp Checking out work trees with an unknown branch is intentionally not supported.
517 38e11793 2018-06-13 stsp .It Fl p Ar path-prefix
518 38e11793 2018-06-13 stsp Restrict the work tree to a subset of the repository's tree hierarchy.
519 38e11793 2018-06-13 stsp Only files beneath the specified
520 38e11793 2018-06-13 stsp .Ar path-prefix
521 38e11793 2018-06-13 stsp will be checked out.
522 38e11793 2018-06-13 stsp .El
523 97b3a7be 2019-07-09 stsp .It Cm co
524 97b3a7be 2019-07-09 stsp Short alias for
525 97b3a7be 2019-07-09 stsp .Cm checkout .
526 dfc23429 2019-08-11 stsp .It Cm update Oo Fl b Ar branch Oc Oo Fl c Ar commit Oc Op Ar path ...
527 4f331d3a 2020-04-01 stsp Update an existing work tree to a different
528 4f331d3a 2020-04-01 stsp .Ar commit .
529 4f331d3a 2020-04-01 stsp Change existing files in the work tree as necessary to match file contents
530 4f331d3a 2020-04-01 stsp of this commit.
531 4f331d3a 2020-04-01 stsp Preserve any local changes in the work tree and merge them with the
532 4f331d3a 2020-04-01 stsp incoming changes.
533 4f331d3a 2020-04-01 stsp .Pp
534 5036ab18 2020-04-18 stsp Files which already contain merge conflicts will not be updated to avoid
535 5036ab18 2020-04-18 stsp further complications.
536 5036ab18 2020-04-18 stsp Such files will be updated when
537 5036ab18 2020-04-18 stsp .Cm got update
538 5036ab18 2020-04-18 stsp is run again after merge conflicts have been resolved.
539 5036ab18 2020-04-18 stsp If the conflicting changes are no longer needed affected files can be
540 5036ab18 2020-04-18 stsp reverted with
541 5036ab18 2020-04-18 stsp .Cm got revert
542 5036ab18 2020-04-18 stsp before running
543 5036ab18 2020-04-18 stsp .Cm got update
544 5036ab18 2020-04-18 stsp again.
545 5036ab18 2020-04-18 stsp .Pp
546 7f838b36 2019-02-08 stsp Show the status of each affected file, using the following status codes:
547 7f838b36 2019-02-08 stsp .Bl -column YXZ description
548 7f838b36 2019-02-08 stsp .It U Ta file was updated and contained no local changes
549 7f838b36 2019-02-08 stsp .It G Ta file was updated and local changes were merged cleanly
550 7f838b36 2019-02-08 stsp .It C Ta file was updated and conflicts occurred during merge
551 7f838b36 2019-02-08 stsp .It D Ta file was deleted
552 7f838b36 2019-02-08 stsp .It A Ta new file was added
553 1dd86744 2019-08-12 anthony .It \(a~ Ta versioned file is obstructed by a non-regular file
554 a378724f 2019-02-10 stsp .It ! Ta a missing versioned file was restored
555 5036ab18 2020-04-18 stsp .It # Ta file was not updated because it contains merge conflicts
556 3b9f0f87 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
557 7f838b36 2019-02-08 stsp .El
558 7f838b36 2019-02-08 stsp .Pp
559 f2ea84fa 2019-07-27 stsp If no
560 c4cdcb68 2019-04-03 stsp .Ar path
561 f2ea84fa 2019-07-27 stsp is specified, update the entire work tree.
562 f2ea84fa 2019-07-27 stsp Otherwise, restrict the update operation to files at or within the
563 f2ea84fa 2019-07-27 stsp specified paths.
564 f2ea84fa 2019-07-27 stsp Each path is required to exist in the update operation's target commit.
565 f2ea84fa 2019-07-27 stsp Files in the work tree outside specified paths will remain unchanged and
566 f2ea84fa 2019-07-27 stsp will retain their previously recorded base commit.
567 f2cf8fbb 2019-04-04 stsp Some
568 f2cf8fbb 2019-04-04 stsp .Nm
569 f2cf8fbb 2019-04-04 stsp commands may refuse to run while the work tree contains files from
570 c4cdcb68 2019-04-03 stsp multiple base commits.
571 f2cf8fbb 2019-04-04 stsp The base commit of such a work tree can be made consistent by running
572 47ec7be7 2019-05-12 stsp .Cm got update
573 47ec7be7 2019-05-12 stsp across the entire work tree.
574 024e9686 2019-05-14 stsp Specifying a
575 024e9686 2019-05-14 stsp .Ar path
576 024e9686 2019-05-14 stsp is incompatible with the
577 024e9686 2019-05-14 stsp .Fl b
578 024e9686 2019-05-14 stsp option.
579 7f838b36 2019-02-08 stsp .Pp
580 4ed9f614 2019-08-04 stsp .Cm got update
581 4ed9f614 2019-08-04 stsp cannot update paths with staged changes.
582 4ed9f614 2019-08-04 stsp If changes have been staged with
583 4ed9f614 2019-08-04 stsp .Cm got stage ,
584 bc3056e3 2019-08-18 stsp these changes must first be committed with
585 4ed9f614 2019-08-04 stsp .Cm got commit
586 4ed9f614 2019-08-04 stsp or unstaged with
587 4ed9f614 2019-08-04 stsp .Cm got unstage .
588 4ed9f614 2019-08-04 stsp .Pp
589 507dc3bb 2018-12-29 stsp The options for
590 507dc3bb 2018-12-29 stsp .Cm got update
591 507dc3bb 2018-12-29 stsp are as follows:
592 507dc3bb 2018-12-29 stsp .Bl -tag -width Ds
593 024e9686 2019-05-14 stsp .It Fl b Ar branch
594 024e9686 2019-05-14 stsp Switch the work tree's branch reference to the specified
595 024e9686 2019-05-14 stsp .Ar branch
596 024e9686 2019-05-14 stsp before updating the work tree.
597 024e9686 2019-05-14 stsp This option requires that all paths in the work tree are updated.
598 4f331d3a 2020-04-01 stsp .Pp
599 4f331d3a 2020-04-01 stsp As usual, any local changes in the work tree will be preserved.
600 4f331d3a 2020-04-01 stsp This can be useful when switching to a newly created branch in order
601 4f331d3a 2020-04-01 stsp to commit existing local changes to this branch.
602 4f331d3a 2020-04-01 stsp .Pp
603 4f331d3a 2020-04-01 stsp Any local changes must be dealt with separately in order to obtain a
604 4f331d3a 2020-04-01 stsp work tree with pristine file contents corresponding exactly to the specified
605 4f331d3a 2020-04-01 stsp .Ar branch .
606 4f331d3a 2020-04-01 stsp Such changes could first be committed to a different branch with
607 4f331d3a 2020-04-01 stsp .Cm got commit ,
608 4f331d3a 2020-04-01 stsp or could be discarded with
609 4f331d3a 2020-04-01 stsp .Cm got revert .
610 507dc3bb 2018-12-29 stsp .It Fl c Ar commit
611 507dc3bb 2018-12-29 stsp Update the work tree to the specified
612 507dc3bb 2018-12-29 stsp .Ar commit .
613 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
614 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
615 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
616 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
617 024e9686 2019-05-14 stsp If this option is not specified, the most recent commit on the work tree's
618 024e9686 2019-05-14 stsp branch will be used.
619 507dc3bb 2018-12-29 stsp .El
620 97b3a7be 2019-07-09 stsp .It Cm up
621 97b3a7be 2019-07-09 stsp Short alias for
622 97b3a7be 2019-07-09 stsp .Cm update .
623 081470ac 2020-08-13 stsp .It Cm status Oo Fl s Ar status-codes Oc Op Ar path ...
624 6cd959e6 2019-03-26 stsp Show the current modification status of files in a work tree,
625 6bad629b 2019-02-04 stsp using the following status codes:
626 6bad629b 2019-02-04 stsp .Bl -column YXZ description
627 6bad629b 2019-02-04 stsp .It M Ta modified file
628 079890a9 2019-03-26 stsp .It A Ta file scheduled for addition in next commit
629 079890a9 2019-03-26 stsp .It D Ta file scheduled for deletion in next commit
630 7154f6ce 2019-03-27 stsp .It C Ta modified or added file which contains merge conflicts
631 6bad629b 2019-02-04 stsp .It ! Ta versioned file was expected on disk but is missing
632 1dd86744 2019-08-12 anthony .It \(a~ Ta versioned file is obstructed by a non-regular file
633 6bad629b 2019-02-04 stsp .It ? Ta unversioned item not tracked by
634 6bad629b 2019-02-04 stsp .Nm
635 1ebedb77 2019-10-19 stsp .It m Ta modified file modes (executable bit only)
636 2a06fe5f 2019-08-24 stsp .It N Ta non-existent
637 2a06fe5f 2019-08-24 stsp .Ar path
638 2a06fe5f 2019-08-24 stsp specified on the command line
639 6bad629b 2019-02-04 stsp .El
640 6bad629b 2019-02-04 stsp .Pp
641 72ea6654 2019-07-27 stsp If no
642 927df6b7 2019-02-10 stsp .Ar path
643 72ea6654 2019-07-27 stsp is specified, show modifications in the entire work tree.
644 72ea6654 2019-07-27 stsp Otherwise, show modifications at or within the specified paths.
645 4ed9f614 2019-08-04 stsp .Pp
646 4ed9f614 2019-08-04 stsp If changes have been staged with
647 4ed9f614 2019-08-04 stsp .Cm got stage ,
648 4ed9f614 2019-08-04 stsp staged changes are shown in the second output column, using the following
649 4ed9f614 2019-08-04 stsp status codes:
650 4ed9f614 2019-08-04 stsp .Bl -column YXZ description
651 4ed9f614 2019-08-04 stsp .It M Ta file modification is staged
652 4ed9f614 2019-08-04 stsp .It A Ta file addition is staged
653 4ed9f614 2019-08-04 stsp .It D Ta file deletion is staged
654 4ed9f614 2019-08-04 stsp .El
655 4ed9f614 2019-08-04 stsp .Pp
656 95ac67f0 2019-08-08 stsp Changes created on top of staged changes are indicated in the first column:
657 4ed9f614 2019-08-04 stsp .Bl -column YXZ description
658 95ac67f0 2019-08-08 stsp .It MM Ta file was modified after earlier changes have been staged
659 95ac67f0 2019-08-08 stsp .It MA Ta file was modified after having been staged for addition
660 4ed9f614 2019-08-04 stsp .El
661 6841da00 2019-08-08 stsp .Pp
662 081470ac 2020-08-13 stsp The options for
663 081470ac 2020-08-13 stsp .Cm got status
664 081470ac 2020-08-13 stsp are as follows:
665 081470ac 2020-08-13 stsp .Bl -tag -width Ds
666 081470ac 2020-08-13 stsp .It Fl s Ar status-codes
667 081470ac 2020-08-13 stsp Only show files with a modification status matching any of the
668 081470ac 2020-08-13 stsp single-character status codes contained in the
669 081470ac 2020-08-13 stsp .Ar status-codes
670 081470ac 2020-08-13 stsp argument.
671 081470ac 2020-08-13 stsp Any combination of codes from the above list of possible status codes
672 081470ac 2020-08-13 stsp may be specified.
673 081470ac 2020-08-13 stsp For staged files, status codes displayed in either column will be matched.
674 081470ac 2020-08-13 stsp .El
675 081470ac 2020-08-13 stsp .Pp
676 6841da00 2019-08-08 stsp For compatibility with
677 bd8de430 2019-10-04 stsp .Xr cvs 1
678 bd8de430 2019-10-04 stsp and
679 bd8de430 2019-10-04 stsp .Xr git 1 ,
680 6841da00 2019-08-08 stsp .Cm got status
681 bd8de430 2019-10-04 stsp reads
682 bd8de430 2019-10-04 stsp .Xr glob 7
683 bd8de430 2019-10-04 stsp patterns from
684 6841da00 2019-08-08 stsp .Pa .cvsignore
685 bd8de430 2019-10-04 stsp and
686 bd8de430 2019-10-04 stsp .Pa .gitignore
687 6841da00 2019-08-08 stsp files in each traversed directory and will not display unversioned files
688 bd8de430 2019-10-04 stsp which match these patterns.
689 bd8de430 2019-10-04 stsp As an extension to
690 6841da00 2019-08-08 stsp .Xr glob 7
691 bd8de430 2019-10-04 stsp matching rules,
692 bd8de430 2019-10-04 stsp .Cm got status
693 bd8de430 2019-10-04 stsp supports consecutive asterisks,
694 bd8de430 2019-10-04 stsp .Dq ** ,
695 bd8de430 2019-10-04 stsp which will match an arbitrary amount of directories.
696 6841da00 2019-08-08 stsp Unlike
697 6841da00 2019-08-08 stsp .Xr cvs 1 ,
698 6841da00 2019-08-08 stsp .Cm got status
699 6841da00 2019-08-08 stsp only supports a single ignore pattern per line.
700 bd8de430 2019-10-04 stsp Unlike
701 bd8de430 2019-10-04 stsp .Xr git 1 ,
702 bd8de430 2019-10-04 stsp .Cm got status
703 bd8de430 2019-10-04 stsp does not support negated ignore patterns prefixed with
704 bd8de430 2019-10-04 stsp .Dq \&! ,
705 bd8de430 2019-10-04 stsp and gives no special significance to the location of path component separators,
706 bd8de430 2019-10-04 stsp .Dq / ,
707 bd8de430 2019-10-04 stsp in a pattern.
708 97b3a7be 2019-07-09 stsp .It Cm st
709 97b3a7be 2019-07-09 stsp Short alias for
710 97b3a7be 2019-07-09 stsp .Cm status .
711 0208f208 2020-05-05 stsp .It Cm log Oo Fl b Oc Oo Fl c Ar commit Oc Oo Fl C Ar number Oc Oo Fl l Ar N Oc Oo Fl p Oc Oo Fl P Oc Oo Fl s Ar search-pattern Oc Oo Fl r Ar repository-path Oc Oo Fl R Oc Oo Fl x Ar commit Oc Op Ar path
712 38e11793 2018-06-13 stsp Display history of a repository.
713 04ca23f4 2018-07-16 stsp If a
714 04ca23f4 2018-07-16 stsp .Ar path
715 04ca23f4 2018-07-16 stsp is specified, show only commits which modified this path.
716 dc990cbf 2020-02-22 stsp If invoked in a work tree, the
717 dc990cbf 2020-02-22 stsp .Ar path
718 dc990cbf 2020-02-22 stsp is interpreted relative to the current working directory,
719 dc990cbf 2020-02-22 stsp and the work tree's path prefix is implicitly prepended.
720 dc990cbf 2020-02-22 stsp Otherwise, the path is interpreted relative to the repository root.
721 38e11793 2018-06-13 stsp .Pp
722 38e11793 2018-06-13 stsp The options for
723 38e11793 2018-06-13 stsp .Cm got log
724 38e11793 2018-06-13 stsp are as follows:
725 38e11793 2018-06-13 stsp .Bl -tag -width Ds
726 48c8c60d 2020-01-27 stsp .It Fl b
727 1137e0ae 2020-01-27 stsp Display individual commits which were merged into the current branch
728 1137e0ae 2020-01-27 stsp from other branches.
729 48c8c60d 2020-01-27 stsp By default,
730 48c8c60d 2020-01-27 stsp .Cm got log
731 48c8c60d 2020-01-27 stsp shows the linear history of the current branch only.
732 38e11793 2018-06-13 stsp .It Fl c Ar commit
733 38e11793 2018-06-13 stsp Start traversing history at the specified
734 38e11793 2018-06-13 stsp .Ar commit .
735 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
736 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
737 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
738 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
739 1cc14b9f 2019-05-14 stsp If this option is not specified, default to the work tree's current branch
740 1cc14b9f 2019-05-14 stsp if invoked in a work tree, or to the repository's HEAD reference.
741 c0cc5c62 2018-10-18 stsp .It Fl C Ar number
742 c0cc5c62 2018-10-18 stsp Set the number of context lines shown in diffs with
743 c0cc5c62 2018-10-18 stsp .Fl p .
744 c0cc5c62 2018-10-18 stsp By default, 3 lines of context are shown.
745 6238ee32 2018-06-13 stsp .It Fl l Ar N
746 6238ee32 2018-06-13 stsp Limit history traversal to a given number of commits.
747 b1ebc001 2019-08-13 stsp If this option is not specified, a default limit value of zero is used,
748 b1ebc001 2019-08-13 stsp which is treated as an unbounded limit.
749 b1ebc001 2019-08-13 stsp The
750 b1ebc001 2019-08-13 stsp .Ev GOT_LOG_DEFAULT_LIMIT
751 b1ebc001 2019-08-13 stsp environment variable may be set to change this default value.
752 6238ee32 2018-06-13 stsp .It Fl p
753 6238ee32 2018-06-13 stsp Display the patch of modifications made in each commit.
754 44392932 2019-08-25 stsp If a
755 44392932 2019-08-25 stsp .Ar path
756 44392932 2019-08-25 stsp is specified, only show the patch of modifications at or within this path.
757 0208f208 2020-05-05 stsp .It Fl P
758 0208f208 2020-05-05 stsp Display the list of file paths changed in each commit, using the following
759 0208f208 2020-05-05 stsp status codes:
760 0208f208 2020-05-05 stsp .Bl -column YXZ description
761 0208f208 2020-05-05 stsp .It M Ta modified file
762 0208f208 2020-05-05 stsp .It D Ta file was deleted
763 0208f208 2020-05-05 stsp .It A Ta new file was added
764 0208f208 2020-05-05 stsp .It m Ta modified file modes (executable bit only)
765 0208f208 2020-05-05 stsp .El
766 c6390436 2019-11-29 kn .It Fl s Ar search-pattern
767 c6390436 2019-11-29 kn If specified, show only commits with a log message matched by the extended
768 6841bf13 2019-11-29 kn regular expression
769 6841bf13 2019-11-29 kn .Ar search-pattern .
770 0208f208 2020-05-05 stsp When used together with
771 0208f208 2020-05-05 stsp .Fl P
772 0208f208 2020-05-05 stsp then the file paths changed by a commit can be matched as well.
773 6841bf13 2019-11-29 kn Regular expression syntax is documented in
774 6841bf13 2019-11-29 kn .Xr re_format 7 .
775 04ca23f4 2018-07-16 stsp .It Fl r Ar repository-path
776 04ca23f4 2018-07-16 stsp Use the repository at the specified path.
777 04ca23f4 2018-07-16 stsp If not specified, assume the repository is located at or above the current
778 04ca23f4 2018-07-16 stsp working directory.
779 e9cf2e30 2019-02-05 stsp If this directory is a
780 e9cf2e30 2019-02-05 stsp .Nm
781 e9cf2e30 2019-02-05 stsp work tree, use the repository path associated with this work tree.
782 dbec59df 2020-04-18 stsp .It Fl R
783 dbec59df 2020-04-18 stsp Determine a set of commits to display as usual, but display these commits
784 dbec59df 2020-04-18 stsp in reverse order.
785 d1fe46f9 2020-04-18 stsp .It Fl x Ar commit
786 52ab7958 2020-04-18 stsp Stop traversing commit history as soon as the specified
787 d1fe46f9 2020-04-18 stsp .Ar commit
788 52ab7958 2020-04-18 stsp has been traversed.
789 d1fe46f9 2020-04-18 stsp This option has no effect if the specified
790 d1fe46f9 2020-04-18 stsp .Ar commit
791 d1fe46f9 2020-04-18 stsp is never traversed.
792 38e11793 2018-06-13 stsp .El
793 64453f7e 2020-11-21 stsp .It Cm diff Oo Fl a Oc Oo Fl C Ar number Oc Oo Fl r Ar repository-path Oc Oo Fl s Oc Oo Fl w Oc Op Ar object1 Ar object2 | Ar path
794 927df6b7 2019-02-10 stsp When invoked within a work tree with less than two arguments, display
795 bd81cfb7 2020-04-19 stsp local changes in the work tree.
796 927df6b7 2019-02-10 stsp If a
797 927df6b7 2019-02-10 stsp .Ar path
798 927df6b7 2019-02-10 stsp is specified, only show changes within this path.
799 927df6b7 2019-02-10 stsp .Pp
800 d24820bf 2019-08-11 stsp If two arguments are provided, treat each argument as a reference, a tag
801 d24820bf 2019-08-11 stsp name, or an object ID SHA1 hash, and display differences between the
802 d24820bf 2019-08-11 stsp corresponding objects.
803 3f8b7d6a 2018-04-01 stsp Both objects must be of the same type (blobs, trees, or commits).
804 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
805 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
806 c0cc5c62 2018-10-18 stsp .Pp
807 c0cc5c62 2018-10-18 stsp The options for
808 c0cc5c62 2018-10-18 stsp .Cm got diff
809 c0cc5c62 2018-10-18 stsp are as follows:
810 c0cc5c62 2018-10-18 stsp .Bl -tag -width Ds
811 64453f7e 2020-11-21 stsp .It Fl a
812 64453f7e 2020-11-21 stsp Treat file contents as ASCII text even if binary data is detected.
813 c0cc5c62 2018-10-18 stsp .It Fl C Ar number
814 c0cc5c62 2018-10-18 stsp Set the number of context lines shown in the diff.
815 c0cc5c62 2018-10-18 stsp By default, 3 lines of context are shown.
816 b72f483a 2019-02-05 stsp .It Fl r Ar repository-path
817 b72f483a 2019-02-05 stsp Use the repository at the specified path.
818 b72f483a 2019-02-05 stsp If not specified, assume the repository is located at or above the current
819 b72f483a 2019-02-05 stsp working directory.
820 b72f483a 2019-02-05 stsp If this directory is a
821 b72f483a 2019-02-05 stsp .Nm
822 b72f483a 2019-02-05 stsp work tree, use the repository path associated with this work tree.
823 4ed9f614 2019-08-04 stsp .It Fl s
824 4ed9f614 2019-08-04 stsp Show changes staged with
825 4ed9f614 2019-08-04 stsp .Cm got stage
826 bd81cfb7 2020-04-19 stsp instead of showing local changes in the work tree.
827 4ed9f614 2019-08-04 stsp This option is only valid when
828 4ed9f614 2019-08-04 stsp .Cm got diff
829 4ed9f614 2019-08-04 stsp is invoked in a work tree.
830 63035f9f 2019-10-06 stsp .It Fl w
831 63035f9f 2019-10-06 stsp Ignore whitespace-only changes.
832 c0cc5c62 2018-10-18 stsp .El
833 bc26cce8 2019-08-04 stsp .It Cm di
834 bc26cce8 2019-08-04 stsp Short alias for
835 bc26cce8 2019-08-04 stsp .Cm diff .
836 dfc23429 2019-08-11 stsp .It Cm blame Oo Fl c Ar commit Oc Oo Fl r Ar repository-path Oc Ar path
837 1ff8e573 2018-08-02 stsp Display line-by-line history of a file at the specified path.
838 1ff8e573 2018-08-02 stsp .Pp
839 1ff8e573 2018-08-02 stsp The options for
840 1ff8e573 2018-08-02 stsp .Cm got blame
841 1ff8e573 2018-08-02 stsp are as follows:
842 1ff8e573 2018-08-02 stsp .Bl -tag -width Ds
843 1ff8e573 2018-08-02 stsp .It Fl c Ar commit
844 1ff8e573 2018-08-02 stsp Start traversing history at the specified
845 1ff8e573 2018-08-02 stsp .Ar commit .
846 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
847 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
848 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
849 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
850 1ff8e573 2018-08-02 stsp .It Fl r Ar repository-path
851 1ff8e573 2018-08-02 stsp Use the repository at the specified path.
852 1ff8e573 2018-08-02 stsp If not specified, assume the repository is located at or above the current
853 1ff8e573 2018-08-02 stsp working directory.
854 0c06baac 2019-02-05 stsp If this directory is a
855 0c06baac 2019-02-05 stsp .Nm
856 0c06baac 2019-02-05 stsp work tree, use the repository path associated with this work tree.
857 5c860e29 2018-03-12 stsp .El
858 bc26cce8 2019-08-04 stsp .It Cm bl
859 bc26cce8 2019-08-04 stsp Short alias for
860 bc26cce8 2019-08-04 stsp .Cm blame .
861 dfc23429 2019-08-11 stsp .It Cm tree Oo Fl c Ar commit Oc Oo Fl r Ar repository-path Oc Oo Fl i Oc Oo Fl R Oc Op Ar path
862 5de5890b 2018-10-18 stsp Display a listing of files and directories at the specified
863 5de5890b 2018-10-18 stsp directory path in the repository.
864 db0c2996 2019-02-10 stsp Entries shown in this listing may carry one of the following trailing
865 db0c2996 2019-02-10 stsp annotations:
866 db0c2996 2019-02-10 stsp .Bl -column YXZ description
867 848d6979 2019-08-12 stsp .It @ Ta entry is a symbolic link
868 db0c2996 2019-02-10 stsp .It / Ta entry is a directory
869 db0c2996 2019-02-10 stsp .It * Ta entry is an executable file
870 63c5ca5d 2019-08-24 stsp .It $ Ta entry is a Git submodule
871 db0c2996 2019-02-10 stsp .El
872 0d6c6ee3 2020-05-20 stsp .Pp
873 0d6c6ee3 2020-05-20 stsp Symbolic link entries are also annotated with the target path of the link.
874 db0c2996 2019-02-10 stsp .Pp
875 0c849583 2019-02-05 stsp If no
876 0c849583 2019-02-05 stsp .Ar path
877 0c849583 2019-02-05 stsp is specified, list the repository path corresponding to the current
878 0c849583 2019-02-05 stsp directory of the work tree, or the root directory of the repository
879 0c849583 2019-02-05 stsp if there is no work tree.
880 5de5890b 2018-10-18 stsp .Pp
881 5de5890b 2018-10-18 stsp The options for
882 5de5890b 2018-10-18 stsp .Cm got tree
883 5de5890b 2018-10-18 stsp are as follows:
884 5de5890b 2018-10-18 stsp .Bl -tag -width Ds
885 5de5890b 2018-10-18 stsp .It Fl c Ar commit
886 5de5890b 2018-10-18 stsp List files and directories as they appear in the specified
887 5de5890b 2018-10-18 stsp .Ar commit .
888 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
889 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
890 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
891 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
892 5de5890b 2018-10-18 stsp .It Fl r Ar repository-path
893 5de5890b 2018-10-18 stsp Use the repository at the specified path.
894 5de5890b 2018-10-18 stsp If not specified, assume the repository is located at or above the current
895 5de5890b 2018-10-18 stsp working directory.
896 0c849583 2019-02-05 stsp If this directory is a
897 0c849583 2019-02-05 stsp .Nm
898 0c849583 2019-02-05 stsp work tree, use the repository path associated with this work tree.
899 5de5890b 2018-10-18 stsp .It Fl i
900 5de5890b 2018-10-18 stsp Show object IDs of files (blob objects) and directories (tree objects).
901 c1669e2e 2019-01-09 stsp .It Fl R
902 0c849583 2019-02-05 stsp Recurse into sub-directories in the repository.
903 d0eebce4 2019-03-11 stsp .El
904 bc26cce8 2019-08-04 stsp .It Cm tr
905 bc26cce8 2019-08-04 stsp Short alias for
906 bc26cce8 2019-08-04 stsp .Cm tree .
907 e31abbf2 2020-03-22 stsp .It Cm ref Oo Fl r Ar repository-path Oc Oo Fl l Oc Oo Fl c Ar object Oc Oo Fl s Ar reference Oc Oo Fl d Oc Op Ar name
908 d0eebce4 2019-03-11 stsp Manage references in a repository.
909 d0eebce4 2019-03-11 stsp .Pp
910 e31abbf2 2020-03-22 stsp References may be listed, created, deleted, and changed.
911 e31abbf2 2020-03-22 stsp When creating, deleting, or changing a reference the specified
912 e31abbf2 2020-03-22 stsp .Ar name
913 e31abbf2 2020-03-22 stsp must be an absolute reference name, i.e. it must begin with
914 f16e4044 2019-10-09 stsp .Dq refs/ .
915 e31abbf2 2020-03-22 stsp .Pp
916 d0eebce4 2019-03-11 stsp The options for
917 d0eebce4 2019-03-11 stsp .Cm got ref
918 d0eebce4 2019-03-11 stsp are as follows:
919 d0eebce4 2019-03-11 stsp .Bl -tag -width Ds
920 d0eebce4 2019-03-11 stsp .It Fl r Ar repository-path
921 d0eebce4 2019-03-11 stsp Use the repository at the specified path.
922 d0eebce4 2019-03-11 stsp If not specified, assume the repository is located at or above the current
923 d0eebce4 2019-03-11 stsp working directory.
924 d0eebce4 2019-03-11 stsp If this directory is a
925 d0eebce4 2019-03-11 stsp .Nm
926 d0eebce4 2019-03-11 stsp work tree, use the repository path associated with this work tree.
927 d0eebce4 2019-03-11 stsp .It Fl l
928 b2070a3f 2020-03-22 stsp List references in the repository.
929 b2070a3f 2020-03-22 stsp If no
930 b2070a3f 2020-03-22 stsp .Ar name
931 b2070a3f 2020-03-22 stsp is specified, list all existing references in the repository.
932 b2070a3f 2020-03-22 stsp If
933 b2070a3f 2020-03-22 stsp .Ar name
934 b2070a3f 2020-03-22 stsp is a reference namespace, list all references in this namespace.
935 b2070a3f 2020-03-22 stsp Otherwise, show only the reference with the given
936 b2070a3f 2020-03-22 stsp .Ar name .
937 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
938 e31abbf2 2020-03-22 stsp .Fl r .
939 e31abbf2 2020-03-22 stsp .It Fl c Ar object
940 e31abbf2 2020-03-22 stsp Create a reference or change an existing reference.
941 e31abbf2 2020-03-22 stsp The reference with the specified
942 e31abbf2 2020-03-22 stsp .Ar name
943 e31abbf2 2020-03-22 stsp will point at the specified
944 e31abbf2 2020-03-22 stsp .Ar object.
945 e31abbf2 2020-03-22 stsp The expected
946 e31abbf2 2020-03-22 stsp .Ar object
947 e31abbf2 2020-03-22 stsp argument is a ID SHA1 hash or an existing reference or tag name which will
948 e31abbf2 2020-03-22 stsp be resolved to the ID of a corresponding commit, tree, tag, or blob object.
949 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
950 e31abbf2 2020-03-22 stsp .Fl r .
951 e31abbf2 2020-03-22 stsp .It Fl s Ar reference
952 e31abbf2 2020-03-22 stsp Create a symbolic reference, or change an existing symbolic reference.
953 e31abbf2 2020-03-22 stsp The symbolic reference with the specified
954 e31abbf2 2020-03-22 stsp .Ar name
955 e31abbf2 2020-03-22 stsp will point at the specified
956 e31abbf2 2020-03-22 stsp .Ar reference
957 e31abbf2 2020-03-22 stsp which must already exist in the repository.
958 d1c1ae5f 2019-08-12 stsp Care should be taken not to create loops between references when
959 d1c1ae5f 2019-08-12 stsp this option is used.
960 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
961 e31abbf2 2020-03-22 stsp .Fl r .
962 e31abbf2 2020-03-22 stsp .It Fl d
963 e31abbf2 2020-03-22 stsp Delete the reference with the specified
964 e31abbf2 2020-03-22 stsp .Ar name
965 e31abbf2 2020-03-22 stsp from the repository.
966 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
967 e31abbf2 2020-03-22 stsp .Fl r .
968 4e759de4 2019-06-26 stsp .El
969 da76fce2 2020-02-24 stsp .It Cm branch Oo Fl c Ar commit Oc Oo Fl r Ar repository-path Oc Oo Fl l Oc Oo Fl d Ar name Oc Oo Fl n Oc Op Ar name
970 da76fce2 2020-02-24 stsp Create, list, or delete branches.
971 4e759de4 2019-06-26 stsp .Pp
972 4e759de4 2019-06-26 stsp Branches are managed via references which live in the
973 4e759de4 2019-06-26 stsp .Dq refs/heads/
974 4e759de4 2019-06-26 stsp reference namespace.
975 4e759de4 2019-06-26 stsp The
976 4e759de4 2019-06-26 stsp .Cm got branch
977 4e759de4 2019-06-26 stsp command operates on references in this namespace only.
978 4e759de4 2019-06-26 stsp .Pp
979 ad89fa31 2019-10-04 stsp If invoked in a work tree without any arguments, print the name of the
980 ad89fa31 2019-10-04 stsp work tree's current branch.
981 da76fce2 2020-02-24 stsp .Pp
982 a74f7e83 2019-11-10 stsp If a
983 a74f7e83 2019-11-10 stsp .Ar name
984 a74f7e83 2019-11-10 stsp argument is passed, attempt to create a branch reference with the given name.
985 a74f7e83 2019-11-10 stsp By default the new branch reference will point at the latest commit on the
986 a74f7e83 2019-11-10 stsp work tree's current branch if invoked in a work tree, and otherwise to a commit
987 a74f7e83 2019-11-10 stsp resolved via the repository's HEAD reference.
988 4e759de4 2019-06-26 stsp .Pp
989 da76fce2 2020-02-24 stsp If invoked in a work tree, once the branch was created successfully
990 da76fce2 2020-02-24 stsp switch the work tree's head reference to the newly created branch and
991 da76fce2 2020-02-24 stsp update files across the entire work tree, just like
992 da76fce2 2020-02-24 stsp .Cm got update -b Ar name
993 da76fce2 2020-02-24 stsp would do.
994 da76fce2 2020-02-24 stsp Show the status of each affected file, using the following status codes:
995 da76fce2 2020-02-24 stsp .Bl -column YXZ description
996 da76fce2 2020-02-24 stsp .It U Ta file was updated and contained no local changes
997 da76fce2 2020-02-24 stsp .It G Ta file was updated and local changes were merged cleanly
998 da76fce2 2020-02-24 stsp .It C Ta file was updated and conflicts occurred during merge
999 da76fce2 2020-02-24 stsp .It D Ta file was deleted
1000 da76fce2 2020-02-24 stsp .It A Ta new file was added
1001 da76fce2 2020-02-24 stsp .It \(a~ Ta versioned file is obstructed by a non-regular file
1002 da76fce2 2020-02-24 stsp .It ! Ta a missing versioned file was restored
1003 da76fce2 2020-02-24 stsp .El
1004 da76fce2 2020-02-24 stsp .Pp
1005 4e759de4 2019-06-26 stsp The options for
1006 4e759de4 2019-06-26 stsp .Cm got branch
1007 4e759de4 2019-06-26 stsp are as follows:
1008 4e759de4 2019-06-26 stsp .Bl -tag -width Ds
1009 a74f7e83 2019-11-10 stsp .It Fl c Ar commit
1010 a74f7e83 2019-11-10 stsp Make a newly created branch reference point at the specified
1011 a74f7e83 2019-11-10 stsp .Ar commit .
1012 a74f7e83 2019-11-10 stsp The expected
1013 a74f7e83 2019-11-10 stsp .Ar commit
1014 a74f7e83 2019-11-10 stsp argument is a commit ID SHA1 hash or an existing reference
1015 a74f7e83 2019-11-10 stsp or tag name which will be resolved to a commit ID.
1016 4e759de4 2019-06-26 stsp .It Fl r Ar repository-path
1017 4e759de4 2019-06-26 stsp Use the repository at the specified path.
1018 4e759de4 2019-06-26 stsp If not specified, assume the repository is located at or above the current
1019 4e759de4 2019-06-26 stsp working directory.
1020 4e759de4 2019-06-26 stsp If this directory is a
1021 4e759de4 2019-06-26 stsp .Nm
1022 4e759de4 2019-06-26 stsp work tree, use the repository path associated with this work tree.
1023 4e759de4 2019-06-26 stsp .It Fl l
1024 4e759de4 2019-06-26 stsp List all existing branches in the repository.
1025 ba882ee3 2019-07-11 stsp If invoked in a work tree, the work tree's current branch is shown
1026 ba882ee3 2019-07-11 stsp with one the following annotations:
1027 ba882ee3 2019-07-11 stsp .Bl -column YXZ description
1028 ba882ee3 2019-07-11 stsp .It * Ta work tree's base commit matches the branch tip
1029 1dd86744 2019-08-12 anthony .It \(a~ Ta work tree's base commit is out-of-date
1030 ba882ee3 2019-07-11 stsp .El
1031 4e759de4 2019-06-26 stsp .It Fl d Ar name
1032 4e759de4 2019-06-26 stsp Delete the branch with the specified name from the repository.
1033 7acfb25b 2019-07-11 stsp Only the branch reference is deleted.
1034 7acfb25b 2019-07-11 stsp Any commit, tree, and blob objects belonging to the branch
1035 74d012d1 2019-07-11 stsp remain in the repository and may be removed separately with
1036 ce33d90e 2019-07-14 stsp Git's garbage collector.
1037 da76fce2 2020-02-24 stsp .It Fl n
1038 da76fce2 2020-02-24 stsp Do not switch and update the work tree after creating a new branch.
1039 5de5890b 2018-10-18 stsp .El
1040 97b3a7be 2019-07-09 stsp .It Cm br
1041 97b3a7be 2019-07-09 stsp Short alias for
1042 97b3a7be 2019-07-09 stsp .Cm branch .
1043 80106605 2020-02-24 stsp .It Cm tag Oo Fl c Ar commit Oc Oo Fl m Ar message Oc Oo Fl r Ar repository-path Oc Oo Fl l Oc Ar name
1044 8e7bd50a 2019-08-22 stsp Manage tags in a repository.
1045 8e7bd50a 2019-08-22 stsp .Pp
1046 8e7bd50a 2019-08-22 stsp Tags are managed via references which live in the
1047 8e7bd50a 2019-08-22 stsp .Dq refs/tags/
1048 8e7bd50a 2019-08-22 stsp reference namespace.
1049 8e7bd50a 2019-08-22 stsp The
1050 8e7bd50a 2019-08-22 stsp .Cm got tag
1051 8e7bd50a 2019-08-22 stsp command operates on references in this namespace only.
1052 b3cd068e 2019-08-22 stsp References in this namespace point at tag objects which contain a pointer
1053 b3cd068e 2019-08-22 stsp to another object, a tag message, as well as author and timestamp information.
1054 8e7bd50a 2019-08-22 stsp .Pp
1055 80106605 2020-02-24 stsp Attempt to create a tag with the given
1056 8e7bd50a 2019-08-22 stsp .Ar name ,
1057 8e7bd50a 2019-08-22 stsp and make this tag point at the given
1058 8e7bd50a 2019-08-22 stsp .Ar commit .
1059 8e7bd50a 2019-08-22 stsp If no commit is specified, default to the latest commit on the work tree's
1060 8e7bd50a 2019-08-22 stsp current branch if invoked in a work tree, and to a commit resolved via
1061 8e7bd50a 2019-08-22 stsp the repository's HEAD reference otherwise.
1062 8e7bd50a 2019-08-22 stsp .Pp
1063 8e7bd50a 2019-08-22 stsp The options for
1064 8e7bd50a 2019-08-22 stsp .Cm got tag
1065 8e7bd50a 2019-08-22 stsp are as follows:
1066 8e7bd50a 2019-08-22 stsp .Bl -tag -width Ds
1067 80106605 2020-02-24 stsp .It Fl c Ar commit
1068 80106605 2020-02-24 stsp Make the newly created tag reference point at the specified
1069 80106605 2020-02-24 stsp .Ar commit .
1070 80106605 2020-02-24 stsp The expected
1071 80106605 2020-02-24 stsp .Ar commit
1072 80106605 2020-02-24 stsp argument is a commit ID SHA1 hash or an existing reference or tag name which
1073 80106605 2020-02-24 stsp will be resolved to a commit ID.
1074 80106605 2020-02-24 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1075 80106605 2020-02-24 stsp automatically, provided the abbreviation is unique.
1076 8e7bd50a 2019-08-22 stsp .It Fl m Ar message
1077 80106605 2020-02-24 stsp Use the specified tag message when creating the new tag.
1078 8e7bd50a 2019-08-22 stsp Without the
1079 8e7bd50a 2019-08-22 stsp .Fl m
1080 8e7bd50a 2019-08-22 stsp option,
1081 3a62228f 2019-11-08 stsp .Cm got tag
1082 8e7bd50a 2019-08-22 stsp opens a temporary file in an editor where a tag message can be written.
1083 8e7bd50a 2019-08-22 stsp .It Fl r Ar repository-path
1084 8e7bd50a 2019-08-22 stsp Use the repository at the specified path.
1085 8e7bd50a 2019-08-22 stsp If not specified, assume the repository is located at or above the current
1086 8e7bd50a 2019-08-22 stsp working directory.
1087 8e7bd50a 2019-08-22 stsp If this directory is a
1088 8e7bd50a 2019-08-22 stsp .Nm
1089 8e7bd50a 2019-08-22 stsp work tree, use the repository path associated with this work tree.
1090 8e7bd50a 2019-08-22 stsp .It Fl l
1091 8e7bd50a 2019-08-22 stsp List all existing tags in the repository instead of creating a new tag.
1092 8e7bd50a 2019-08-22 stsp If this option is used, no other command-line arguments are allowed.
1093 8e7bd50a 2019-08-22 stsp .El
1094 8e7bd50a 2019-08-22 stsp .Pp
1095 8e7bd50a 2019-08-22 stsp By design, the
1096 8e7bd50a 2019-08-22 stsp .Cm got tag
1097 8e7bd50a 2019-08-22 stsp command will not delete tags or change existing tags.
1098 8e7bd50a 2019-08-22 stsp If a tag must be deleted, the
1099 8e7bd50a 2019-08-22 stsp .Cm got ref
1100 8e7bd50a 2019-08-22 stsp command may be used to delete a tag's reference.
1101 8e7bd50a 2019-08-22 stsp This should only be done if the tag has not already been copied to
1102 8e7bd50a 2019-08-22 stsp another repository.
1103 022fae89 2019-12-06 tracey .It Cm add Oo Fl R Oc Oo Fl I Oc Ar path ...
1104 8125ddca 2019-05-11 stsp Schedule unversioned files in a work tree for addition to the
1105 d00136be 2019-03-26 stsp repository in the next commit.
1106 4e68cba3 2019-11-23 stsp .Pp
1107 4e68cba3 2019-11-23 stsp The options for
1108 4e68cba3 2019-11-23 stsp .Cm got add
1109 4e68cba3 2019-11-23 stsp are as follows:
1110 4e68cba3 2019-11-23 stsp .Bl -tag -width Ds
1111 4e68cba3 2019-11-23 stsp .It Fl R
1112 4e68cba3 2019-11-23 stsp Permit recursion into directories.
1113 4e68cba3 2019-11-23 stsp If this option is not specified,
1114 4e68cba3 2019-11-23 stsp .Cm got add
1115 4e68cba3 2019-11-23 stsp will refuse to run if a specified
1116 4e68cba3 2019-11-23 stsp .Ar path
1117 4e68cba3 2019-11-23 stsp is a directory.
1118 022fae89 2019-12-06 tracey .It Fl I
1119 022fae89 2019-12-06 tracey With -R, add files even if they match a
1120 022fae89 2019-12-06 tracey .Cm got status
1121 022fae89 2019-12-06 tracey ignore pattern.
1122 4e68cba3 2019-11-23 stsp .El
1123 766841c2 2020-08-13 stsp .It Cm remove Oo Fl f Oc Oo Fl k Oc Oo Fl R Oc Oo Fl s Ar status-codes Oc Ar path ...
1124 17ed4618 2019-06-02 stsp Remove versioned files from a work tree and schedule them for deletion
1125 2ec1f75b 2019-03-26 stsp from the repository in the next commit.
1126 2ec1f75b 2019-03-26 stsp .Pp
1127 2ec1f75b 2019-03-26 stsp The options for
1128 86d25a1b 2019-07-11 stsp .Cm got remove
1129 2ec1f75b 2019-03-26 stsp are as follows:
1130 2ec1f75b 2019-03-26 stsp .Bl -tag -width Ds
1131 2ec1f75b 2019-03-26 stsp .It Fl f
1132 bd81cfb7 2020-04-19 stsp Perform the operation even if a file contains local modifications.
1133 70e3e7f5 2019-12-13 tracey .It Fl k
1134 70e3e7f5 2019-12-13 tracey Keep affected files on disk.
1135 f2a9dc41 2019-12-13 tracey .It Fl R
1136 f2a9dc41 2019-12-13 tracey Permit recursion into directories.
1137 f2a9dc41 2019-12-13 tracey If this option is not specified,
1138 f2a9dc41 2019-12-13 tracey .Cm got remove
1139 f2a9dc41 2019-12-13 tracey will refuse to run if a specified
1140 f2a9dc41 2019-12-13 tracey .Ar path
1141 f2a9dc41 2019-12-13 tracey is a directory.
1142 766841c2 2020-08-13 stsp .It Fl s Ar status-codes
1143 766841c2 2020-08-13 stsp Only delete files with a modification status matching one of the
1144 766841c2 2020-08-13 stsp single-character status codes contained in the
1145 766841c2 2020-08-13 stsp .Ar status-codes
1146 766841c2 2020-08-13 stsp argument.
1147 766841c2 2020-08-13 stsp The following status codes may be specified:
1148 766841c2 2020-08-13 stsp .Bl -column YXZ description
1149 766841c2 2020-08-13 stsp .It M Ta modified file (this implies the
1150 766841c2 2020-08-13 stsp .Fl f
1151 766841c2 2020-08-13 stsp option)
1152 766841c2 2020-08-13 stsp .It ! Ta versioned file expected on disk but missing
1153 766841c2 2020-08-13 stsp .El
1154 d0eebce4 2019-03-11 stsp .El
1155 648e4ef7 2019-07-09 stsp .It Cm rm
1156 648e4ef7 2019-07-09 stsp Short alias for
1157 648e4ef7 2019-07-09 stsp .Cm remove .
1158 dfc23429 2019-08-11 stsp .It Cm revert Oo Fl p Oc Oo Fl F Ar response-script Oc Oo Fl R Oc Ar path ...
1159 bd81cfb7 2020-04-19 stsp Revert any local changes in files at the specified paths in a work tree.
1160 a129376b 2019-03-28 stsp File contents will be overwritten with those contained in the
1161 1dd86744 2019-08-12 anthony work tree's base commit.
1162 1dd86744 2019-08-12 anthony There is no way to bring discarded changes back after
1163 a129376b 2019-03-28 stsp .Cm got revert !
1164 a129376b 2019-03-28 stsp .Pp
1165 e20a8b6f 2019-06-04 stsp If a file was added with
1166 a129376b 2019-03-28 stsp .Cm got add
1167 a129376b 2019-03-28 stsp it will become an unversioned file again.
1168 e20a8b6f 2019-06-04 stsp If a file was deleted with
1169 86d25a1b 2019-07-11 stsp .Cm got remove
1170 a129376b 2019-03-28 stsp it will be restored.
1171 0f6d7415 2019-08-08 stsp .Pp
1172 0f6d7415 2019-08-08 stsp The options for
1173 0f6d7415 2019-08-08 stsp .Cm got revert
1174 0f6d7415 2019-08-08 stsp are as follows:
1175 0f6d7415 2019-08-08 stsp .Bl -tag -width Ds
1176 33aa809d 2019-08-08 stsp .It Fl p
1177 33aa809d 2019-08-08 stsp Instead of reverting all changes in files, interactively select or reject
1178 33aa809d 2019-08-08 stsp changes to revert based on
1179 33aa809d 2019-08-08 stsp .Dq y
1180 33aa809d 2019-08-08 stsp (revert change),
1181 33aa809d 2019-08-08 stsp .Dq n
1182 33aa809d 2019-08-08 stsp (keep change), and
1183 33aa809d 2019-08-08 stsp .Dq q
1184 33aa809d 2019-08-08 stsp (quit reverting this file) responses.
1185 33aa809d 2019-08-08 stsp If a file is in modified status, individual patches derived from the
1186 33aa809d 2019-08-08 stsp modified file content can be reverted.
1187 33aa809d 2019-08-08 stsp Files in added or deleted status may only be reverted in their entirety.
1188 33aa809d 2019-08-08 stsp .It Fl F Ar response-script
1189 33aa809d 2019-08-08 stsp With the
1190 33aa809d 2019-08-08 stsp .Fl p
1191 33aa809d 2019-08-08 stsp option, read
1192 33aa809d 2019-08-08 stsp .Dq y ,
1193 33aa809d 2019-08-08 stsp .Dq n ,
1194 33aa809d 2019-08-08 stsp and
1195 33aa809d 2019-08-08 stsp .Dq q
1196 33aa809d 2019-08-08 stsp responses line-by-line from the specified
1197 33aa809d 2019-08-08 stsp .Ar response-script
1198 33aa809d 2019-08-08 stsp file instead of prompting interactively.
1199 0f6d7415 2019-08-08 stsp .It Fl R
1200 0f6d7415 2019-08-08 stsp Permit recursion into directories.
1201 0f6d7415 2019-08-08 stsp If this option is not specified,
1202 0f6d7415 2019-08-08 stsp .Cm got revert
1203 0f6d7415 2019-08-08 stsp will refuse to run if a specified
1204 0f6d7415 2019-08-08 stsp .Ar path
1205 0f6d7415 2019-08-08 stsp is a directory.
1206 0f6d7415 2019-08-08 stsp .El
1207 97b3a7be 2019-07-09 stsp .It Cm rv
1208 97b3a7be 2019-07-09 stsp Short alias for
1209 97b3a7be 2019-07-09 stsp .Cm revert .
1210 35213c7c 2020-07-23 stsp .It Cm commit Oo Fl m Ar message Oc Oo Fl S Oc Op Ar path ...
1211 4ed9f614 2019-08-04 stsp Create a new commit in the repository from changes in a work tree
1212 15cd91f7 2019-05-12 stsp and use this commit as the new base commit for the work tree.
1213 5c1e53bc 2019-07-28 stsp If no
1214 90e8619e 2019-07-25 stsp .Ar path
1215 4ed9f614 2019-08-04 stsp is specified, commit all changes in the work tree.
1216 4ed9f614 2019-08-04 stsp Otherwise, commit changes at or within the specified paths.
1217 15cd91f7 2019-05-12 stsp .Pp
1218 4ed9f614 2019-08-04 stsp If changes have been explicitly staged for commit with
1219 1dd86744 2019-08-12 anthony .Cm got stage ,
1220 4ed9f614 2019-08-04 stsp only commit staged changes and reject any specified paths which
1221 4ed9f614 2019-08-04 stsp have not been staged.
1222 4ed9f614 2019-08-04 stsp .Pp
1223 15cd91f7 2019-05-12 stsp Show the status of each affected file, using the following status codes:
1224 15cd91f7 2019-05-12 stsp .Bl -column YXZ description
1225 15cd91f7 2019-05-12 stsp .It M Ta modified file
1226 15cd91f7 2019-05-12 stsp .It D Ta file was deleted
1227 15cd91f7 2019-05-12 stsp .It A Ta new file was added
1228 1ebedb77 2019-10-19 stsp .It m Ta modified file modes (executable bit only)
1229 15cd91f7 2019-05-12 stsp .El
1230 15cd91f7 2019-05-12 stsp .Pp
1231 996d5ccd 2019-08-05 stsp Files which are not part of the new commit will retain their previously
1232 996d5ccd 2019-08-05 stsp recorded base commit.
1233 15cd91f7 2019-05-12 stsp Some
1234 15cd91f7 2019-05-12 stsp .Nm
1235 15cd91f7 2019-05-12 stsp commands may refuse to run while the work tree contains files from
1236 15cd91f7 2019-05-12 stsp multiple base commits.
1237 15cd91f7 2019-05-12 stsp The base commit of such a work tree can be made consistent by running
1238 47ec7be7 2019-05-12 stsp .Cm got update
1239 47ec7be7 2019-05-12 stsp across the entire work tree.
1240 15cd91f7 2019-05-12 stsp .Pp
1241 15cd91f7 2019-05-12 stsp The
1242 15cd91f7 2019-05-12 stsp .Cm got commit
1243 15cd91f7 2019-05-12 stsp command requires the
1244 74416c47 2019-05-09 stsp .Ev GOT_AUTHOR
1245 aba9c984 2019-09-08 stsp environment variable to be set,
1246 257add31 2020-09-09 stsp unless an author has been configured in
1247 257add31 2020-09-09 stsp .Xr got.conf 5
1248 257add31 2020-09-09 stsp or Git's
1249 aba9c984 2019-09-08 stsp .Dv user.name
1250 aba9c984 2019-09-08 stsp and
1251 709ae9eb 2019-09-08 stsp .Dv user.email
1252 709ae9eb 2019-09-08 stsp configuration settings can be
1253 aba9c984 2019-09-08 stsp obtained from the repository's
1254 aba9c984 2019-09-08 stsp .Pa .git/config
1255 c9956ddf 2019-09-08 stsp file or from Git's global
1256 c9956ddf 2019-09-08 stsp .Pa ~/.gitconfig
1257 c9956ddf 2019-09-08 stsp configuration file.
1258 74416c47 2019-05-09 stsp .Pp
1259 74416c47 2019-05-09 stsp The options for
1260 74416c47 2019-05-09 stsp .Cm got commit
1261 74416c47 2019-05-09 stsp are as follows:
1262 74416c47 2019-05-09 stsp .Bl -tag -width Ds
1263 74ff3f23 2019-07-07 stsp .It Fl m Ar message
1264 74416c47 2019-05-09 stsp Use the specified log message when creating the new commit.
1265 23594da9 2019-05-13 stsp Without the
1266 23594da9 2019-05-13 stsp .Fl m
1267 23594da9 2019-05-13 stsp option,
1268 23594da9 2019-05-13 stsp .Cm got commit
1269 23594da9 2019-05-13 stsp opens a temporary file in an editor where a log message can be written.
1270 35213c7c 2020-07-23 stsp .It Fl S
1271 af358f55 2020-07-23 stsp Allow the addition of symbolic links which point outside of the path space
1272 af358f55 2020-07-23 stsp that is under version control.
1273 af358f55 2020-07-23 stsp By default,
1274 af358f55 2020-07-23 stsp .Cm got commit
1275 af358f55 2020-07-23 stsp will reject such symbolic links due to safety concerns.
1276 35213c7c 2020-07-23 stsp As a precaution,
1277 35213c7c 2020-07-23 stsp .Nm
1278 af358f55 2020-07-23 stsp may decide to represent such a symbolic link as a regular file which contains
1279 af358f55 2020-07-23 stsp the link's target path, rather than creating an actual symbolic link which
1280 af358f55 2020-07-23 stsp points outside of the work tree.
1281 af358f55 2020-07-23 stsp Use of this option is discouraged because external mechanisms such as
1282 af358f55 2020-07-23 stsp .Dq make obj
1283 af358f55 2020-07-23 stsp are better suited for managing symbolic links to paths not under
1284 af358f55 2020-07-23 stsp version control.
1285 2ec1f75b 2019-03-26 stsp .El
1286 cfce0458 2019-07-28 stsp .Pp
1287 cfce0458 2019-07-28 stsp .Cm got commit
1288 cfce0458 2019-07-28 stsp will refuse to run if certain preconditions are not met.
1289 916f288c 2019-07-30 stsp If the work tree's current branch is not in the
1290 916f288c 2019-07-30 stsp .Dq refs/heads/
1291 916f288c 2019-07-30 stsp reference namespace, new commits may not be created on this branch.
1292 cfce0458 2019-07-28 stsp Local changes may only be committed if they are based on file content
1293 cfce0458 2019-07-28 stsp found in the most recent commit on the work tree's branch.
1294 cfce0458 2019-07-28 stsp If a path is found to be out of date,
1295 cfce0458 2019-07-28 stsp .Cm got update
1296 cfce0458 2019-07-28 stsp must be used first in order to merge local changes with changes made
1297 cfce0458 2019-07-28 stsp in the repository.
1298 97b3a7be 2019-07-09 stsp .It Cm ci
1299 97b3a7be 2019-07-09 stsp Short alias for
1300 97b3a7be 2019-07-09 stsp .Cm commit .
1301 234035bc 2019-06-01 stsp .It Cm cherrypick Ar commit
1302 234035bc 2019-06-01 stsp Merge changes from a single
1303 234035bc 2019-06-01 stsp .Ar commit
1304 234035bc 2019-06-01 stsp into the work tree.
1305 234035bc 2019-06-01 stsp The specified
1306 234035bc 2019-06-01 stsp .Ar commit
1307 234035bc 2019-06-01 stsp must be on a different branch than the work tree's base commit.
1308 a54b6686 2019-06-28 stsp The expected argument is a reference or a commit ID SHA1 hash.
1309 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1310 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
1311 234035bc 2019-06-01 stsp .Pp
1312 234035bc 2019-06-01 stsp Show the status of each affected file, using the following status codes:
1313 234035bc 2019-06-01 stsp .Bl -column YXZ description
1314 234035bc 2019-06-01 stsp .It G Ta file was merged
1315 234035bc 2019-06-01 stsp .It C Ta file was merged and conflicts occurred during merge
1316 234035bc 2019-06-01 stsp .It ! Ta changes destined for a missing file were not merged
1317 234035bc 2019-06-01 stsp .It D Ta file was deleted
1318 2b92fad7 2019-06-02 stsp .It d Ta file's deletion was obstructed by local modifications
1319 234035bc 2019-06-01 stsp .It A Ta new file was added
1320 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1321 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
1322 74416c47 2019-05-09 stsp .El
1323 234035bc 2019-06-01 stsp .Pp
1324 234035bc 2019-06-01 stsp The merged changes will appear as local changes in the work tree, which
1325 234035bc 2019-06-01 stsp may be viewed with
1326 234035bc 2019-06-01 stsp .Cm got diff ,
1327 234035bc 2019-06-01 stsp amended manually or with further
1328 234035bc 2019-06-01 stsp .Cm got cherrypick
1329 bc3056e3 2019-08-18 stsp commands,
1330 234035bc 2019-06-01 stsp committed with
1331 234035bc 2019-06-01 stsp .Cm got commit ,
1332 234035bc 2019-06-01 stsp or discarded again with
1333 234035bc 2019-06-01 stsp .Cm got revert .
1334 234035bc 2019-06-01 stsp .Pp
1335 234035bc 2019-06-01 stsp .Cm got cherrypick
1336 234035bc 2019-06-01 stsp will refuse to run if certain preconditions are not met.
1337 234035bc 2019-06-01 stsp If the work tree contains multiple base commits it must first be updated
1338 234035bc 2019-06-01 stsp to a single base commit with
1339 234035bc 2019-06-01 stsp .Cm got update .
1340 234035bc 2019-06-01 stsp If the work tree already contains files with merge conflicts, these
1341 234035bc 2019-06-01 stsp conflicts must be resolved first.
1342 016477fd 2019-07-09 stsp .It Cm cy
1343 97b3a7be 2019-07-09 stsp Short alias for
1344 97b3a7be 2019-07-09 stsp .Cm cherrypick .
1345 5ef14e63 2019-06-02 stsp .It Cm backout Ar commit
1346 5ef14e63 2019-06-02 stsp Reverse-merge changes from a single
1347 5ef14e63 2019-06-02 stsp .Ar commit
1348 5ef14e63 2019-06-02 stsp into the work tree.
1349 5ef14e63 2019-06-02 stsp The specified
1350 5ef14e63 2019-06-02 stsp .Ar commit
1351 5ef14e63 2019-06-02 stsp must be on the same branch as the work tree's base commit.
1352 a54b6686 2019-06-28 stsp The expected argument is a reference or a commit ID SHA1 hash.
1353 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1354 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
1355 5ef14e63 2019-06-02 stsp .Pp
1356 5ef14e63 2019-06-02 stsp Show the status of each affected file, using the following status codes:
1357 5ef14e63 2019-06-02 stsp .Bl -column YXZ description
1358 5ef14e63 2019-06-02 stsp .It G Ta file was merged
1359 5ef14e63 2019-06-02 stsp .It C Ta file was merged and conflicts occurred during merge
1360 5ef14e63 2019-06-02 stsp .It ! Ta changes destined for a missing file were not merged
1361 5ef14e63 2019-06-02 stsp .It D Ta file was deleted
1362 5ef14e63 2019-06-02 stsp .It d Ta file's deletion was obstructed by local modifications
1363 5ef14e63 2019-06-02 stsp .It A Ta new file was added
1364 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1365 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
1366 234035bc 2019-06-01 stsp .El
1367 5ef14e63 2019-06-02 stsp .Pp
1368 5ef14e63 2019-06-02 stsp The reverse-merged changes will appear as local changes in the work tree,
1369 5ef14e63 2019-06-02 stsp which may be viewed with
1370 5ef14e63 2019-06-02 stsp .Cm got diff ,
1371 5ef14e63 2019-06-02 stsp amended manually or with further
1372 778a73c2 2019-07-12 stsp .Cm got backout
1373 bc3056e3 2019-08-18 stsp commands,
1374 5ef14e63 2019-06-02 stsp committed with
1375 5ef14e63 2019-06-02 stsp .Cm got commit ,
1376 5ef14e63 2019-06-02 stsp or discarded again with
1377 5ef14e63 2019-06-02 stsp .Cm got revert .
1378 5ef14e63 2019-06-02 stsp .Pp
1379 92228c38 2019-06-02 stsp .Cm got backout
1380 92228c38 2019-06-02 stsp will refuse to run if certain preconditions are not met.
1381 92228c38 2019-06-02 stsp If the work tree contains multiple base commits it must first be updated
1382 92228c38 2019-06-02 stsp to a single base commit with
1383 92228c38 2019-06-02 stsp .Cm got update .
1384 92228c38 2019-06-02 stsp If the work tree already contains files with merge conflicts, these
1385 92228c38 2019-06-02 stsp conflicts must be resolved first.
1386 97b3a7be 2019-07-09 stsp .It Cm bo
1387 97b3a7be 2019-07-09 stsp Short alias for
1388 97b3a7be 2019-07-09 stsp .Cm backout .
1389 dfc23429 2019-08-11 stsp .It Cm rebase Oo Fl a Oc Oo Fl c Oc Op Ar branch
1390 818c7501 2019-07-11 stsp Rebase commits on the specified
1391 818c7501 2019-07-11 stsp .Ar branch
1392 818c7501 2019-07-11 stsp onto the tip of the current branch of the work tree.
1393 818c7501 2019-07-11 stsp The
1394 818c7501 2019-07-11 stsp .Ar branch
1395 818c7501 2019-07-11 stsp must share common ancestry with the work tree's current branch.
1396 bc3056e3 2019-08-18 stsp Rebasing begins with the first descendant commit of the youngest
1397 f09e2405 2019-07-11 stsp common ancestor commit shared by the specified
1398 818c7501 2019-07-11 stsp .Ar branch
1399 818c7501 2019-07-11 stsp and the work tree's current branch, and stops once the tip commit
1400 f09e2405 2019-07-11 stsp of the specified
1401 818c7501 2019-07-11 stsp .Ar branch
1402 f09e2405 2019-07-11 stsp has been rebased.
1403 818c7501 2019-07-11 stsp .Pp
1404 2b6826ba 2020-02-24 stsp When
1405 2b6826ba 2020-02-24 stsp .Cm got rebase
1406 2b6826ba 2020-02-24 stsp is used as intended, the specified
1407 2b6826ba 2020-02-24 stsp .Ar branch
1408 c10890ce 2020-02-25 stsp represents a local commit history and may already contain changes
1409 c10890ce 2020-02-25 stsp that are not yet visible in any other repositories.
1410 2b6826ba 2020-02-24 stsp The work tree's current branch, which must be set with
1411 2b6826ba 2020-02-24 stsp .Cm got update -b
1412 2b6826ba 2020-02-24 stsp before starting the
1413 2b6826ba 2020-02-24 stsp .Cm rebase
1414 2b6826ba 2020-02-24 stsp operation, represents a branch from a remote repository which shares
1415 2b6826ba 2020-02-24 stsp a common history with the specified
1416 2b6826ba 2020-02-24 stsp .Ar branch
1417 c10890ce 2020-02-25 stsp but has progressed, and perhaps diverged, due to commits added to the
1418 c10890ce 2020-02-25 stsp remote repository.
1419 2b6826ba 2020-02-24 stsp .Pp
1420 c6b4581b 2019-07-28 stsp Rebased commits are accumulated on a temporary branch which the work tree
1421 c6b4581b 2019-07-28 stsp will remain switched to throughout the entire rebase operation.
1422 c6b4581b 2019-07-28 stsp Commits on this branch represent the same changes with the same log
1423 c6b4581b 2019-07-28 stsp messages as their counterparts on the original
1424 818c7501 2019-07-11 stsp .Ar branch ,
1425 818c7501 2019-07-11 stsp but with different commit IDs.
1426 818c7501 2019-07-11 stsp Once rebasing has completed successfully, the temporary branch becomes
1427 f09e2405 2019-07-11 stsp the new version of the specified
1428 818c7501 2019-07-11 stsp .Ar branch
1429 818c7501 2019-07-11 stsp and the work tree is automatically switched to it.
1430 818c7501 2019-07-11 stsp .Pp
1431 818c7501 2019-07-11 stsp While rebasing commits, show the status of each affected file,
1432 818c7501 2019-07-11 stsp using the following status codes:
1433 818c7501 2019-07-11 stsp .Bl -column YXZ description
1434 818c7501 2019-07-11 stsp .It G Ta file was merged
1435 818c7501 2019-07-11 stsp .It C Ta file was merged and conflicts occurred during merge
1436 818c7501 2019-07-11 stsp .It ! Ta changes destined for a missing file were not merged
1437 818c7501 2019-07-11 stsp .It D Ta file was deleted
1438 818c7501 2019-07-11 stsp .It d Ta file's deletion was obstructed by local modifications
1439 818c7501 2019-07-11 stsp .It A Ta new file was added
1440 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1441 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
1442 5ef14e63 2019-06-02 stsp .El
1443 818c7501 2019-07-11 stsp .Pp
1444 f09e2405 2019-07-11 stsp If merge conflicts occur the rebase operation is interrupted and may
1445 f09e2405 2019-07-11 stsp be continued once conflicts have been resolved.
1446 818c7501 2019-07-11 stsp Alternatively, the rebase operation may be aborted which will leave
1447 818c7501 2019-07-11 stsp .Ar branch
1448 818c7501 2019-07-11 stsp unmodified and the work tree switched back to its original branch.
1449 818c7501 2019-07-11 stsp .Pp
1450 ff0d2220 2019-07-11 stsp If a merge conflict is resolved in a way which renders the merged
1451 f09e2405 2019-07-11 stsp change into a no-op change, the corresponding commit will be elided
1452 f09e2405 2019-07-11 stsp when the rebase operation continues.
1453 ff0d2220 2019-07-11 stsp .Pp
1454 818c7501 2019-07-11 stsp .Cm got rebase
1455 818c7501 2019-07-11 stsp will refuse to run if certain preconditions are not met.
1456 a85446b2 2020-01-04 stsp If the work tree is not yet fully updated to the tip commit of its
1457 a85446b2 2020-01-04 stsp branch then the work tree must first be updated with
1458 818c7501 2019-07-11 stsp .Cm got update .
1459 4ed9f614 2019-08-04 stsp If changes have been staged with
1460 4ed9f614 2019-08-04 stsp .Cm got stage ,
1461 bc3056e3 2019-08-18 stsp these changes must first be committed with
1462 4ed9f614 2019-08-04 stsp .Cm got commit
1463 4ed9f614 2019-08-04 stsp or unstaged with
1464 4ed9f614 2019-08-04 stsp .Cm got unstage .
1465 f09e2405 2019-07-11 stsp If the work tree contains local changes, these changes must first be
1466 f09e2405 2019-07-11 stsp committed with
1467 f09e2405 2019-07-11 stsp .Cm got commit
1468 f09e2405 2019-07-11 stsp or reverted with
1469 f09e2405 2019-07-11 stsp .Cm got revert .
1470 64c6d990 2019-07-11 stsp If the
1471 64c6d990 2019-07-11 stsp .Ar branch
1472 64c6d990 2019-07-11 stsp contains changes to files outside of the work tree's path prefix,
1473 64c6d990 2019-07-11 stsp the work tree cannot be used to rebase this branch.
1474 818c7501 2019-07-11 stsp .Pp
1475 7d5807f4 2019-07-11 stsp The
1476 7d5807f4 2019-07-11 stsp .Cm got update
1477 7d5807f4 2019-07-11 stsp and
1478 7d5807f4 2019-07-11 stsp .Cm got commit
1479 7d5807f4 2019-07-11 stsp commands will refuse to run while a rebase operation is in progress.
1480 7d5807f4 2019-07-11 stsp Other commands which manipulate the work tree may be used for
1481 7d5807f4 2019-07-11 stsp conflict resolution purposes.
1482 818c7501 2019-07-11 stsp .Pp
1483 818c7501 2019-07-11 stsp The options for
1484 818c7501 2019-07-11 stsp .Cm got rebase
1485 818c7501 2019-07-11 stsp are as follows:
1486 818c7501 2019-07-11 stsp .Bl -tag -width Ds
1487 818c7501 2019-07-11 stsp .It Fl a
1488 818c7501 2019-07-11 stsp Abort an interrupted rebase operation.
1489 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
1490 818c7501 2019-07-11 stsp .It Fl c
1491 06067b48 2019-07-11 stsp Continue an interrupted rebase operation.
1492 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
1493 818c7501 2019-07-11 stsp .El
1494 818c7501 2019-07-11 stsp .It Cm rb
1495 818c7501 2019-07-11 stsp Short alias for
1496 818c7501 2019-07-11 stsp .Cm rebase .
1497 466785b9 2020-12-10 jrick .It Cm histedit Oo Fl a Oc Oo Fl c Oc Oo Fl f Oc Oo Fl F Ar histedit-script Oc Oo Fl m Oc
1498 0ebf8283 2019-07-24 stsp Edit commit history between the work tree's current base commit and
1499 0ebf8283 2019-07-24 stsp the tip commit of the work tree's current branch.
1500 6e54d307 2020-02-24 stsp .Pp
1501 6e54d307 2020-02-24 stsp Before starting a
1502 6e54d307 2020-02-24 stsp .Cm histedit
1503 6e54d307 2020-02-24 stsp operation the work tree's current branch must be set with
1504 6e54d307 2020-02-24 stsp .Cm got update -b
1505 6e54d307 2020-02-24 stsp to the branch which should be edited, unless this branch is already the
1506 6e54d307 2020-02-24 stsp current branch of the work tree.
1507 6e54d307 2020-02-24 stsp The tip of this branch represents the upper bound (inclusive) of commits
1508 6e54d307 2020-02-24 stsp touched by the
1509 6e54d307 2020-02-24 stsp .Cm histedit
1510 6e54d307 2020-02-24 stsp operation.
1511 0ebf8283 2019-07-24 stsp .Pp
1512 6e54d307 2020-02-24 stsp Furthermore, the work tree's base commit
1513 6e54d307 2020-02-24 stsp must be set with
1514 6e54d307 2020-02-24 stsp .Cm got update -c
1515 6e54d307 2020-02-24 stsp to a point in this branch's commit history where editing should begin.
1516 6e54d307 2020-02-24 stsp This commit represents the lower bound (non-inclusive) of commits touched
1517 6e54d307 2020-02-24 stsp by the
1518 6e54d307 2020-02-24 stsp .Cm histedit
1519 6e54d307 2020-02-24 stsp operation.
1520 6e54d307 2020-02-24 stsp .Pp
1521 0ebf8283 2019-07-24 stsp Editing of commit history is controlled via a
1522 0ebf8283 2019-07-24 stsp .Ar histedit script
1523 46fa4c83 2020-02-24 stsp which can be written in an editor based on a template, passed on the
1524 46fa4c83 2020-02-24 stsp command line, or generated with the
1525 466785b9 2020-12-10 jrick .Fl f
1526 466785b9 2020-12-10 jrick or
1527 083957f4 2020-02-24 stsp .Fl m
1528 466785b9 2020-12-10 jrick options.
1529 083957f4 2020-02-24 stsp .Pp
1530 0ebf8283 2019-07-24 stsp The format of the histedit script is line-based.
1531 0ebf8283 2019-07-24 stsp Each line in the script begins with a command name, followed by
1532 0ebf8283 2019-07-24 stsp whitespace and an argument.
1533 0ebf8283 2019-07-24 stsp For most commands, the expected argument is a commit ID SHA1 hash.
1534 0ebf8283 2019-07-24 stsp Any remaining text on the line is ignored.
1535 0ebf8283 2019-07-24 stsp Lines which begin with the
1536 0ebf8283 2019-07-24 stsp .Sq #
1537 0ebf8283 2019-07-24 stsp character are ignored entirely.
1538 0ebf8283 2019-07-24 stsp .Pp
1539 0ebf8283 2019-07-24 stsp The available commands are as follows:
1540 0ebf8283 2019-07-24 stsp .Bl -column YXZ pick-commit
1541 0ebf8283 2019-07-24 stsp .It pick Ar commit Ta Use the specified commit as it is.
1542 a698f62e 2019-07-25 stsp .It edit Ar commit Ta Use the specified commit but once changes have been
1543 0ebf8283 2019-07-24 stsp merged into the work tree interrupt the histedit operation for amending.
1544 0ebf8283 2019-07-24 stsp .It fold Ar commit Ta Combine the specified commit with the next commit
1545 0ebf8283 2019-07-24 stsp listed further below that will be used.
1546 0ebf8283 2019-07-24 stsp .It drop Ar commit Ta Remove this commit from the edited history.
1547 0ebf8283 2019-07-24 stsp .It mesg Ar log-message Ta Use the specified single-line log message for
1548 0ebf8283 2019-07-24 stsp the commit on the previous line.
1549 0ebf8283 2019-07-24 stsp If the log message argument is left empty, open an editor where a new
1550 0ebf8283 2019-07-24 stsp log message can be written.
1551 0ebf8283 2019-07-24 stsp .El
1552 0ebf8283 2019-07-24 stsp .Pp
1553 ba67992e 2019-07-25 stsp Every commit in the history being edited must be mentioned in the script.
1554 0ebf8283 2019-07-24 stsp Lines may be re-ordered to change the order of commits in the edited history.
1555 5b87815e 2020-03-05 stsp No commit may be listed more than once.
1556 0ebf8283 2019-07-24 stsp .Pp
1557 c6b4581b 2019-07-28 stsp Edited commits are accumulated on a temporary branch which the work tree
1558 c6b4581b 2019-07-28 stsp will remain switched to throughout the entire histedit operation.
1559 0ebf8283 2019-07-24 stsp Once history editing has completed successfully, the temporary branch becomes
1560 498a90b7 2019-07-25 stsp the new version of the work tree's branch and the work tree is automatically
1561 498a90b7 2019-07-25 stsp switched to it.
1562 0ebf8283 2019-07-24 stsp .Pp
1563 0ebf8283 2019-07-24 stsp While merging commits, show the status of each affected file,
1564 0ebf8283 2019-07-24 stsp using the following status codes:
1565 0ebf8283 2019-07-24 stsp .Bl -column YXZ description
1566 0ebf8283 2019-07-24 stsp .It G Ta file was merged
1567 0ebf8283 2019-07-24 stsp .It C Ta file was merged and conflicts occurred during merge
1568 0ebf8283 2019-07-24 stsp .It ! Ta changes destined for a missing file were not merged
1569 0ebf8283 2019-07-24 stsp .It D Ta file was deleted
1570 0ebf8283 2019-07-24 stsp .It d Ta file's deletion was obstructed by local modifications
1571 0ebf8283 2019-07-24 stsp .It A Ta new file was added
1572 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1573 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
1574 0ebf8283 2019-07-24 stsp .El
1575 0ebf8283 2019-07-24 stsp .Pp
1576 0ebf8283 2019-07-24 stsp If merge conflicts occur the histedit operation is interrupted and may
1577 0ebf8283 2019-07-24 stsp be continued once conflicts have been resolved.
1578 0ebf8283 2019-07-24 stsp Alternatively, the histedit operation may be aborted which will leave
1579 0ebf8283 2019-07-24 stsp the work tree switched back to its original branch.
1580 0ebf8283 2019-07-24 stsp .Pp
1581 0ebf8283 2019-07-24 stsp If a merge conflict is resolved in a way which renders the merged
1582 0ebf8283 2019-07-24 stsp change into a no-op change, the corresponding commit will be elided
1583 0ebf8283 2019-07-24 stsp when the histedit operation continues.
1584 0ebf8283 2019-07-24 stsp .Pp
1585 0ebf8283 2019-07-24 stsp .Cm got histedit
1586 0ebf8283 2019-07-24 stsp will refuse to run if certain preconditions are not met.
1587 c7d20a3f 2019-07-30 stsp If the work tree's current branch is not in the
1588 c7d20a3f 2019-07-30 stsp .Dq refs/heads/
1589 c7d20a3f 2019-07-30 stsp reference namespace, the history of the branch may not be edited.
1590 0ebf8283 2019-07-24 stsp If the work tree contains multiple base commits it must first be updated
1591 0ebf8283 2019-07-24 stsp to a single base commit with
1592 0ebf8283 2019-07-24 stsp .Cm got update .
1593 4ed9f614 2019-08-04 stsp If changes have been staged with
1594 4ed9f614 2019-08-04 stsp .Cm got stage ,
1595 bc3056e3 2019-08-18 stsp these changes must first be committed with
1596 4ed9f614 2019-08-04 stsp .Cm got commit
1597 4ed9f614 2019-08-04 stsp or unstaged with
1598 4ed9f614 2019-08-04 stsp .Cm got unstage .
1599 0ebf8283 2019-07-24 stsp If the work tree contains local changes, these changes must first be
1600 0ebf8283 2019-07-24 stsp committed with
1601 0ebf8283 2019-07-24 stsp .Cm got commit
1602 0ebf8283 2019-07-24 stsp or reverted with
1603 0ebf8283 2019-07-24 stsp .Cm got revert .
1604 0ebf8283 2019-07-24 stsp If the edited history contains changes to files outside of the work tree's
1605 0ebf8283 2019-07-24 stsp path prefix, the work tree cannot be used to edit the history of this branch.
1606 0ebf8283 2019-07-24 stsp .Pp
1607 0ebf8283 2019-07-24 stsp The
1608 7ef62c4e 2020-02-24 stsp .Cm got update ,
1609 7ef62c4e 2020-02-24 stsp .Cm got rebase ,
1610 65db4ffb 2020-02-24 stsp and
1611 65db4ffb 2020-02-24 stsp .Cm got integrate
1612 65db4ffb 2020-02-24 stsp commands will refuse to run while a histedit operation is in progress.
1613 a698f62e 2019-07-25 stsp Other commands which manipulate the work tree may be used, and the
1614 0ebf8283 2019-07-24 stsp .Cm got commit
1615 a698f62e 2019-07-25 stsp command may be used to commit arbitrary changes to the temporary branch
1616 a698f62e 2019-07-25 stsp while the histedit operation is interrupted.
1617 0ebf8283 2019-07-24 stsp .Pp
1618 0ebf8283 2019-07-24 stsp The options for
1619 0ebf8283 2019-07-24 stsp .Cm got histedit
1620 0ebf8283 2019-07-24 stsp are as follows:
1621 0ebf8283 2019-07-24 stsp .Bl -tag -width Ds
1622 0ebf8283 2019-07-24 stsp .It Fl a
1623 0ebf8283 2019-07-24 stsp Abort an interrupted histedit operation.
1624 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
1625 0ebf8283 2019-07-24 stsp .It Fl c
1626 0ebf8283 2019-07-24 stsp Continue an interrupted histedit operation.
1627 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
1628 466785b9 2020-12-10 jrick .It Fl f
1629 466785b9 2020-12-10 jrick Fold all commits into a single commit.
1630 466785b9 2020-12-10 jrick This option is a quick equivalent to a histedit script which folds all
1631 466785b9 2020-12-10 jrick commits, combining them all into one commit.
1632 2a78779e 2020-12-11 stsp The
1633 2a78779e 2020-12-11 stsp .Fl f
1634 2a78779e 2020-12-11 stsp option can only be used when starting a new histedit operation.
1635 466785b9 2020-12-10 jrick If this option is used, no other command-line arguments are allowed.
1636 ddbfac99 2020-02-24 stsp .It Fl F Ar histedit-script
1637 ddbfac99 2020-02-24 stsp Use the specified
1638 ddbfac99 2020-02-24 stsp .Ar histedit-script
1639 ddbfac99 2020-02-24 stsp instead of opening a temporary file in an editor where a histedit script
1640 ddbfac99 2020-02-24 stsp can be written.
1641 083957f4 2020-02-24 stsp .It Fl m
1642 083957f4 2020-02-24 stsp Edit log messages only.
1643 083957f4 2020-02-24 stsp This option is a quick equivalent to a histedit script which edits
1644 2bdefe56 2020-02-24 tracey only log messages but otherwise leaves every picked commit as-is.
1645 083957f4 2020-02-24 stsp The
1646 083957f4 2020-02-24 stsp .Fl m
1647 083957f4 2020-02-24 stsp option can only be used when starting a new histedit operation.
1648 083957f4 2020-02-24 stsp If this option is used, no other command-line arguments are allowed.
1649 818c7501 2019-07-11 stsp .El
1650 0ebf8283 2019-07-24 stsp .It Cm he
1651 0ebf8283 2019-07-24 stsp Short alias for
1652 0ebf8283 2019-07-24 stsp .Cm histedit .
1653 2822a352 2019-10-15 stsp .It Cm integrate Ar branch
1654 2822a352 2019-10-15 stsp Integrate the specified
1655 2822a352 2019-10-15 stsp .Ar branch
1656 2822a352 2019-10-15 stsp into the work tree's current branch.
1657 2822a352 2019-10-15 stsp Files in the work tree are updated to match the contents on the integrated
1658 2822a352 2019-10-15 stsp .Ar branch ,
1659 2822a352 2019-10-15 stsp and the reference of the work tree's branch is changed to point at the
1660 2822a352 2019-10-15 stsp head commit of the integrated
1661 2822a352 2019-10-15 stsp .Ar branch .
1662 2822a352 2019-10-15 stsp .Pp
1663 2822a352 2019-10-15 stsp Both branches can be considered equivalent after integration since they
1664 2822a352 2019-10-15 stsp will be pointing at the same commit.
1665 2822a352 2019-10-15 stsp Both branches remain available for future work, if desired.
1666 2822a352 2019-10-15 stsp In case the integrated
1667 2822a352 2019-10-15 stsp .Ar branch
1668 2822a352 2019-10-15 stsp is no longer needed it may be deleted with
1669 2822a352 2019-10-15 stsp .Cm got branch -d .
1670 2822a352 2019-10-15 stsp .Pp
1671 2822a352 2019-10-15 stsp Show the status of each affected file, using the following status codes:
1672 2822a352 2019-10-15 stsp .Bl -column YXZ description
1673 2822a352 2019-10-15 stsp .It U Ta file was updated
1674 2822a352 2019-10-15 stsp .It D Ta file was deleted
1675 2822a352 2019-10-15 stsp .It A Ta new file was added
1676 2822a352 2019-10-15 stsp .It \(a~ Ta versioned file is obstructed by a non-regular file
1677 2822a352 2019-10-15 stsp .It ! Ta a missing versioned file was restored
1678 2822a352 2019-10-15 stsp .El
1679 2822a352 2019-10-15 stsp .Pp
1680 2822a352 2019-10-15 stsp .Cm got integrate
1681 2822a352 2019-10-15 stsp will refuse to run if certain preconditions are not met.
1682 2822a352 2019-10-15 stsp Most importantly, the
1683 2822a352 2019-10-15 stsp .Ar branch
1684 2822a352 2019-10-15 stsp must have been rebased onto the work tree's current branch with
1685 2822a352 2019-10-15 stsp .Cm got rebase
1686 2822a352 2019-10-15 stsp before it can be integrated, in order to linearize commit history and
1687 2822a352 2019-10-15 stsp resolve merge conflicts.
1688 2822a352 2019-10-15 stsp If the work tree contains multiple base commits it must first be updated
1689 2822a352 2019-10-15 stsp to a single base commit with
1690 2822a352 2019-10-15 stsp .Cm got update .
1691 2822a352 2019-10-15 stsp If changes have been staged with
1692 2822a352 2019-10-15 stsp .Cm got stage ,
1693 2822a352 2019-10-15 stsp these changes must first be committed with
1694 2822a352 2019-10-15 stsp .Cm got commit
1695 2822a352 2019-10-15 stsp or unstaged with
1696 2822a352 2019-10-15 stsp .Cm got unstage .
1697 2822a352 2019-10-15 stsp If the work tree contains local changes, these changes must first be
1698 2822a352 2019-10-15 stsp committed with
1699 2822a352 2019-10-15 stsp .Cm got commit
1700 2822a352 2019-10-15 stsp or reverted with
1701 2822a352 2019-10-15 stsp .Cm got revert .
1702 2822a352 2019-10-15 stsp .It Cm ig
1703 2822a352 2019-10-15 stsp Short alias for
1704 2822a352 2019-10-15 stsp .Cm integrate .
1705 35213c7c 2020-07-23 stsp .It Cm stage Oo Fl l Oc Oo Fl p Oc Oo Fl F Ar response-script Oc Oo Fl S Oc Op Ar path ...
1706 2db2652d 2019-08-07 stsp Stage local changes for inclusion in the next commit.
1707 2db2652d 2019-08-07 stsp If no
1708 2db2652d 2019-08-07 stsp .Ar path
1709 2db2652d 2019-08-07 stsp is specified, stage all changes in the work tree.
1710 2db2652d 2019-08-07 stsp Otherwise, stage changes at or within the specified paths.
1711 4ed9f614 2019-08-04 stsp Paths may be staged if they are added, modified, or deleted according to
1712 4ed9f614 2019-08-04 stsp .Cm got status .
1713 4ed9f614 2019-08-04 stsp .Pp
1714 9d8b19a4 2019-08-04 stsp Show the status of each affected file, using the following status codes:
1715 9d8b19a4 2019-08-04 stsp .Bl -column YXZ description
1716 9d8b19a4 2019-08-04 stsp .It A Ta file addition has been staged
1717 9d8b19a4 2019-08-04 stsp .It M Ta file modification has been staged
1718 9d8b19a4 2019-08-04 stsp .It D Ta file deletion has been staged
1719 9d8b19a4 2019-08-04 stsp .El
1720 9d8b19a4 2019-08-04 stsp .Pp
1721 9d8b19a4 2019-08-04 stsp Staged file contents are saved in newly created blob objects in the repository.
1722 52c8d4ac 2019-08-04 stsp These blobs will be referred to by tree objects once staged changes have been
1723 9d8b19a4 2019-08-04 stsp committed.
1724 9d8b19a4 2019-08-04 stsp .Pp
1725 890ea719 2019-08-04 stsp Staged changes affect the behaviour of
1726 4ed9f614 2019-08-04 stsp .Cm got commit ,
1727 4ed9f614 2019-08-04 stsp .Cm got status ,
1728 4ed9f614 2019-08-04 stsp and
1729 4ed9f614 2019-08-04 stsp .Cm got diff .
1730 4ed9f614 2019-08-04 stsp While paths with staged changes exist, the
1731 4ed9f614 2019-08-04 stsp .Cm got commit
1732 4ed9f614 2019-08-04 stsp command will refuse to commit any paths which do not have staged changes.
1733 4ed9f614 2019-08-04 stsp Local changes created on top of staged changes can only be committed if
1734 4ed9f614 2019-08-04 stsp the path is staged again, or if the staged changes are committed first.
1735 4ed9f614 2019-08-04 stsp The
1736 4ed9f614 2019-08-04 stsp .Cm got status
1737 4ed9f614 2019-08-04 stsp command will show both local changes and staged changes.
1738 4ed9f614 2019-08-04 stsp The
1739 4ed9f614 2019-08-04 stsp .Cm got diff
1740 ecf14362 2019-08-04 stsp command is able to display local changes relative to staged changes,
1741 ecf14362 2019-08-04 stsp and to display staged changes relative to the repository.
1742 4ed9f614 2019-08-04 stsp The
1743 4ed9f614 2019-08-04 stsp .Cm got revert
1744 4ed9f614 2019-08-04 stsp command cannot revert staged changes but may be used to revert
1745 4f2494e6 2019-08-08 stsp local changes created on top of staged changes.
1746 4ed9f614 2019-08-04 stsp .Pp
1747 4ed9f614 2019-08-04 stsp The options for
1748 4ed9f614 2019-08-04 stsp .Cm got stage
1749 4ed9f614 2019-08-04 stsp are as follows:
1750 4ed9f614 2019-08-04 stsp .Bl -tag -width Ds
1751 4ed9f614 2019-08-04 stsp .It Fl l
1752 4ed9f614 2019-08-04 stsp Instead of staging new changes, list paths which are already staged,
1753 9d8b19a4 2019-08-04 stsp along with the IDs of staged blob objects and stage status codes.
1754 9d8b19a4 2019-08-04 stsp If paths were provided in the command line show the staged paths
1755 1dd86744 2019-08-12 anthony among the specified paths.
1756 1dd86744 2019-08-12 anthony Otherwise, show all staged paths.
1757 dc424a06 2019-08-07 stsp .It Fl p
1758 dc424a06 2019-08-07 stsp Instead of staging the entire content of a changed file, interactively
1759 dc424a06 2019-08-07 stsp select or reject changes for staging based on
1760 dc424a06 2019-08-07 stsp .Dq y
1761 6d23ec10 2019-08-08 stsp (stage change),
1762 dc424a06 2019-08-07 stsp .Dq n
1763 6d23ec10 2019-08-08 stsp (reject change), and
1764 b353a198 2019-08-07 stsp .Dq q
1765 6d23ec10 2019-08-08 stsp (quit staging this file) responses.
1766 dc424a06 2019-08-07 stsp If a file is in modified status, individual patches derived from the
1767 dc424a06 2019-08-07 stsp modified file content can be staged.
1768 6d23ec10 2019-08-08 stsp Files in added or deleted status may only be staged or rejected in
1769 6d23ec10 2019-08-08 stsp their entirety.
1770 3a070a2b 2019-08-07 stsp .It Fl F Ar response-script
1771 dc424a06 2019-08-07 stsp With the
1772 dc424a06 2019-08-07 stsp .Fl p
1773 3a070a2b 2019-08-07 stsp option, read
1774 3a070a2b 2019-08-07 stsp .Dq y ,
1775 3a070a2b 2019-08-07 stsp .Dq n ,
1776 3a070a2b 2019-08-07 stsp and
1777 3a070a2b 2019-08-07 stsp .Dq q
1778 0e2f5884 2019-08-07 stsp responses line-by-line from the specified
1779 0e2f5884 2019-08-07 stsp .Ar response-script
1780 0e2f5884 2019-08-07 stsp file instead of prompting interactively.
1781 35213c7c 2020-07-23 stsp .It Fl S
1782 af358f55 2020-07-23 stsp Allow staging of symbolic links which point outside of the path space
1783 af358f55 2020-07-23 stsp that is under version control.
1784 af358f55 2020-07-23 stsp By default,
1785 af358f55 2020-07-23 stsp .Cm got stage
1786 af358f55 2020-07-23 stsp will reject such symbolic links due to safety concerns.
1787 35213c7c 2020-07-23 stsp As a precaution,
1788 35213c7c 2020-07-23 stsp .Nm
1789 af358f55 2020-07-23 stsp may decide to represent such a symbolic link as a regular file which contains
1790 af358f55 2020-07-23 stsp the link's target path, rather than creating an actual symbolic link which
1791 af358f55 2020-07-23 stsp points outside of the work tree.
1792 af358f55 2020-07-23 stsp Use of this option is discouraged because external mechanisms such as
1793 af358f55 2020-07-23 stsp .Dq make obj
1794 af358f55 2020-07-23 stsp are better suited for managing symbolic links to paths not under
1795 af358f55 2020-07-23 stsp version control.
1796 4ed9f614 2019-08-04 stsp .El
1797 4ed9f614 2019-08-04 stsp .Pp
1798 4ed9f614 2019-08-04 stsp .Cm got stage
1799 4ed9f614 2019-08-04 stsp will refuse to run if certain preconditions are not met.
1800 4ed9f614 2019-08-04 stsp If a file contains merge conflicts, these conflicts must be resolved first.
1801 4ed9f614 2019-08-04 stsp If a file is found to be out of date relative to the head commit on the
1802 4ed9f614 2019-08-04 stsp work tree's current branch, the file must be updated with
1803 4ed9f614 2019-08-04 stsp .Cm got update
1804 4ed9f614 2019-08-04 stsp before it can be staged (however, this does not prevent the file from
1805 4ed9f614 2019-08-04 stsp becoming out-of-date at some point after having been staged).
1806 4ed9f614 2019-08-04 stsp .Pp
1807 4ed9f614 2019-08-04 stsp The
1808 4ed9f614 2019-08-04 stsp .Cm got update ,
1809 4ed9f614 2019-08-04 stsp .Cm got rebase ,
1810 4ed9f614 2019-08-04 stsp and
1811 4ed9f614 2019-08-04 stsp .Cm got histedit
1812 4ed9f614 2019-08-04 stsp commands will refuse to run while staged changes exist.
1813 4ed9f614 2019-08-04 stsp If staged changes cannot be committed because a staged path
1814 4ed9f614 2019-08-04 stsp is out of date, the path must be unstaged with
1815 4ed9f614 2019-08-04 stsp .Cm got unstage
1816 4ed9f614 2019-08-04 stsp before it can be updated with
1817 4ed9f614 2019-08-04 stsp .Cm got update ,
1818 4ed9f614 2019-08-04 stsp and may then be staged again if necessary.
1819 4ed9f614 2019-08-04 stsp .It Cm sg
1820 4ed9f614 2019-08-04 stsp Short alias for
1821 4ed9f614 2019-08-04 stsp .Cm stage .
1822 dfc23429 2019-08-11 stsp .It Cm unstage Oo Fl p Oc Oo Fl F Ar response-script Oc Op Ar path ...
1823 4ed9f614 2019-08-04 stsp Merge staged changes back into the work tree and put affected paths
1824 4ed9f614 2019-08-04 stsp back into non-staged status.
1825 4ed9f614 2019-08-04 stsp If no
1826 4ed9f614 2019-08-04 stsp .Ar path
1827 4ed9f614 2019-08-04 stsp is specified, unstage all staged changes across the entire work tree.
1828 2db2652d 2019-08-07 stsp Otherwise, unstage changes at or within the specified paths.
1829 4ed9f614 2019-08-04 stsp .Pp
1830 4ed9f614 2019-08-04 stsp Show the status of each affected file, using the following status codes:
1831 4ed9f614 2019-08-04 stsp .Bl -column YXZ description
1832 4ed9f614 2019-08-04 stsp .It G Ta file was unstaged
1833 4ed9f614 2019-08-04 stsp .It C Ta file was unstaged and conflicts occurred during merge
1834 4ed9f614 2019-08-04 stsp .It ! Ta changes destined for a missing file were not merged
1835 4ed9f614 2019-08-04 stsp .It D Ta file was staged as deleted and still is deleted
1836 4ed9f614 2019-08-04 stsp .It d Ta file's deletion was obstructed by local modifications
1837 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1838 4ed9f614 2019-08-04 stsp .El
1839 2e1f37b0 2019-08-08 stsp .Pp
1840 2e1f37b0 2019-08-08 stsp The options for
1841 2e1f37b0 2019-08-08 stsp .Cm got unstage
1842 2e1f37b0 2019-08-08 stsp are as follows:
1843 2e1f37b0 2019-08-08 stsp .Bl -tag -width Ds
1844 2e1f37b0 2019-08-08 stsp .It Fl p
1845 2e1f37b0 2019-08-08 stsp Instead of unstaging the entire content of a changed file, interactively
1846 2e1f37b0 2019-08-08 stsp select or reject changes for unstaging based on
1847 2e1f37b0 2019-08-08 stsp .Dq y
1848 2e1f37b0 2019-08-08 stsp (unstage change),
1849 2e1f37b0 2019-08-08 stsp .Dq n
1850 2e1f37b0 2019-08-08 stsp (keep change staged), and
1851 2e1f37b0 2019-08-08 stsp .Dq q
1852 2e1f37b0 2019-08-08 stsp (quit unstaging this file) responses.
1853 2e1f37b0 2019-08-08 stsp If a file is staged in modified status, individual patches derived from the
1854 2e1f37b0 2019-08-08 stsp staged file content can be unstaged.
1855 2e1f37b0 2019-08-08 stsp Files staged in added or deleted status may only be unstaged in their entirety.
1856 2e1f37b0 2019-08-08 stsp .It Fl F Ar response-script
1857 2e1f37b0 2019-08-08 stsp With the
1858 2e1f37b0 2019-08-08 stsp .Fl p
1859 2e1f37b0 2019-08-08 stsp option, read
1860 2e1f37b0 2019-08-08 stsp .Dq y ,
1861 2e1f37b0 2019-08-08 stsp .Dq n ,
1862 2e1f37b0 2019-08-08 stsp and
1863 2e1f37b0 2019-08-08 stsp .Dq q
1864 2e1f37b0 2019-08-08 stsp responses line-by-line from the specified
1865 2e1f37b0 2019-08-08 stsp .Ar response-script
1866 2e1f37b0 2019-08-08 stsp file instead of prompting interactively.
1867 2e1f37b0 2019-08-08 stsp .El
1868 4ed9f614 2019-08-04 stsp .It Cm ug
1869 4ed9f614 2019-08-04 stsp Short alias for
1870 4ed9f614 2019-08-04 stsp .Cm unstage .
1871 5be72254 2019-08-26 stsp .It Cm cat Oo Fl c Ar commit Oc Oo Fl r Ar repository-path Oc Oo Fl P Oc Ar arg ...
1872 896e9b6f 2019-08-26 stsp Parse and print contents of objects to standard output in a line-based
1873 896e9b6f 2019-08-26 stsp text format.
1874 896e9b6f 2019-08-26 stsp Content of commit, tree, and tag objects is printed in a way similar
1875 896e9b6f 2019-08-26 stsp to the actual content stored in such objects.
1876 896e9b6f 2019-08-26 stsp Blob object contents are printed as they would appear in files on disk.
1877 896e9b6f 2019-08-26 stsp .Pp
1878 896e9b6f 2019-08-26 stsp Attempt to interpret each argument as a reference, a tag name, or
1879 896e9b6f 2019-08-26 stsp an object ID SHA1 hash.
1880 01073a5d 2019-08-22 stsp References will be resolved to an object ID.
1881 01073a5d 2019-08-22 stsp Tag names will resolved to a tag object.
1882 01073a5d 2019-08-22 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1883 01073a5d 2019-08-22 stsp automatically, provided the abbreviation is unique.
1884 01073a5d 2019-08-22 stsp .Pp
1885 896e9b6f 2019-08-26 stsp If none of the above interpretations produce a valid result, or if the
1886 896e9b6f 2019-08-26 stsp .Fl P
1887 896e9b6f 2019-08-26 stsp option is used, attempt to interpret the argument as a path which will
1888 896e9b6f 2019-08-26 stsp be resolved to the ID of an object found at this path in the repository.
1889 896e9b6f 2019-08-26 stsp .Pp
1890 01073a5d 2019-08-22 stsp The options for
1891 01073a5d 2019-08-22 stsp .Cm got cat
1892 01073a5d 2019-08-22 stsp are as follows:
1893 01073a5d 2019-08-22 stsp .Bl -tag -width Ds
1894 896e9b6f 2019-08-26 stsp .It Fl c Ar commit
1895 896e9b6f 2019-08-26 stsp Look up paths in the specified
1896 896e9b6f 2019-08-26 stsp .Ar commit .
1897 896e9b6f 2019-08-26 stsp If this option is not used, paths are looked up in the commit resolved
1898 896e9b6f 2019-08-26 stsp via the repository's HEAD reference.
1899 896e9b6f 2019-08-26 stsp The expected argument is a commit ID SHA1 hash or an existing reference
1900 896e9b6f 2019-08-26 stsp or tag name which will be resolved to a commit ID.
1901 896e9b6f 2019-08-26 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1902 896e9b6f 2019-08-26 stsp automatically, provided the abbreviation is unique.
1903 01073a5d 2019-08-22 stsp .It Fl r Ar repository-path
1904 01073a5d 2019-08-22 stsp Use the repository at the specified path.
1905 01073a5d 2019-08-22 stsp If not specified, assume the repository is located at or above the current
1906 01073a5d 2019-08-22 stsp working directory.
1907 01073a5d 2019-08-22 stsp If this directory is a
1908 01073a5d 2019-08-22 stsp .Nm
1909 01073a5d 2019-08-22 stsp work tree, use the repository path associated with this work tree.
1910 896e9b6f 2019-08-26 stsp .It Fl P
1911 896e9b6f 2019-08-26 stsp Interpret all arguments as paths only.
1912 896e9b6f 2019-08-26 stsp This option can be used to resolve ambiguity in cases where paths
1913 896e9b6f 2019-08-26 stsp look like tag names, reference names, or object IDs.
1914 4ed9f614 2019-08-04 stsp .El
1915 b2118c49 2020-07-28 stsp .It Cm info Op Ar path ...
1916 b2118c49 2020-07-28 stsp Display meta-data stored in a work tree.
1917 b2118c49 2020-07-28 stsp See
1918 b2118c49 2020-07-28 stsp .Xr got-worktree 5
1919 b2118c49 2020-07-28 stsp for details.
1920 b2118c49 2020-07-28 stsp .Pp
1921 b2118c49 2020-07-28 stsp The work tree to use is resolved implicitly by walking upwards from the
1922 b2118c49 2020-07-28 stsp current working directory.
1923 b2118c49 2020-07-28 stsp .Pp
1924 b2118c49 2020-07-28 stsp If one or more
1925 b2118c49 2020-07-28 stsp .Ar path
1926 b2118c49 2020-07-28 stsp arguments are specified, show additional per-file information for tracked
1927 b2118c49 2020-07-28 stsp files located at or within these paths.
1928 b2118c49 2020-07-28 stsp If a
1929 b2118c49 2020-07-28 stsp .Ar path
1930 b2118c49 2020-07-28 stsp argument corresponds to the work tree's root directory, display information
1931 b2118c49 2020-07-28 stsp for all tracked files.
1932 01073a5d 2019-08-22 stsp .El
1933 74416c47 2019-05-09 stsp .Sh ENVIRONMENT
1934 74416c47 2019-05-09 stsp .Bl -tag -width GOT_AUTHOR
1935 74416c47 2019-05-09 stsp .It Ev GOT_AUTHOR
1936 74416c47 2019-05-09 stsp The author's name and email address for
1937 21a44f98 2019-07-15 stsp .Cm got commit
1938 21a44f98 2019-07-15 stsp and
1939 21a44f98 2019-07-15 stsp .Cm got import ,
1940 74416c47 2019-05-09 stsp for example:
1941 aba9c984 2019-09-08 stsp .Dq An Flan Hacker Aq Mt flan_hacker@openbsd.org .
1942 84792843 2019-08-09 stsp Because
1943 0e444aba 2019-08-08 stsp .Xr git 1
1944 84792843 2019-08-09 stsp may fail to parse commits without an email address in author data,
1945 0e444aba 2019-08-08 stsp .Nm
1946 84792843 2019-08-09 stsp attempts to reject
1947 0e444aba 2019-08-08 stsp .Ev GOT_AUTHOR
1948 84792843 2019-08-09 stsp environment variables with a missing email address.
1949 c9956ddf 2019-09-08 stsp .Pp
1950 50b0790e 2020-09-11 stsp .Ev GOT_AUTHOR will be overriden by configuration settings in
1951 50b0790e 2020-09-11 stsp .Xr got.conf 5
1952 50b0790e 2020-09-11 stsp or by Git's
1953 aba9c984 2019-09-08 stsp .Dv user.name
1954 aba9c984 2019-09-08 stsp and
1955 709ae9eb 2019-09-08 stsp .Dv user.email
1956 709ae9eb 2019-09-08 stsp configuration settings in the repository's
1957 aba9c984 2019-09-08 stsp .Pa .git/config
1958 50b0790e 2020-09-11 stsp file.
1959 257add31 2020-09-09 stsp The
1960 c9956ddf 2019-09-08 stsp .Dv user.name
1961 c9956ddf 2019-09-08 stsp and
1962 c9956ddf 2019-09-08 stsp .Dv user.email
1963 c9956ddf 2019-09-08 stsp configuration settings contained in Git's global
1964 c9956ddf 2019-09-08 stsp .Pa ~/.gitconfig
1965 257add31 2020-09-09 stsp configuration file will only be used if neither
1966 257add31 2020-09-09 stsp .Xr got.conf 5
1967 257add31 2020-09-09 stsp nor the
1968 c9956ddf 2019-09-08 stsp .Ev GOT_AUTHOR
1969 257add31 2020-09-09 stsp environment variable provide author information.
1970 1dd86744 2019-08-12 anthony .It Ev VISUAL , EDITOR
1971 23594da9 2019-05-13 stsp The editor spawned by
1972 8e7bd50a 2019-08-22 stsp .Cm got commit ,
1973 46215d2a 2020-09-11 stsp .Cm got histedit ,
1974 8e7bd50a 2019-08-22 stsp .Cm got import ,
1975 8e7bd50a 2019-08-22 stsp or
1976 8e7bd50a 2019-08-22 stsp .Cm got tag .
1977 5b735925 2020-09-15 stsp If not set, the
1978 5b735925 2020-09-15 stsp .Xr ed 1
1979 5b735925 2020-09-15 stsp text editor will be spawned in order to give
1980 5b735925 2020-09-15 stsp .Xr ed 1
1981 5b735925 2020-09-15 stsp the attention it deserves.
1982 b1ebc001 2019-08-13 stsp .It Ev GOT_LOG_DEFAULT_LIMIT
1983 b1ebc001 2019-08-13 stsp The default limit on the number of commits traversed by
1984 b1ebc001 2019-08-13 stsp .Cm got log .
1985 b1ebc001 2019-08-13 stsp If set to zero, the limit is unbounded.
1986 b1ebc001 2019-08-13 stsp This variable will be silently ignored if it is set to a non-numeric value.
1987 74416c47 2019-05-09 stsp .El
1988 257add31 2020-09-09 stsp .Sh FILES
1989 257add31 2020-09-09 stsp .Bl -tag -width packed-refs -compact
1990 257add31 2020-09-09 stsp .It Pa got.conf
1991 257add31 2020-09-09 stsp Repository-wide configuration settings for
1992 257add31 2020-09-09 stsp .Nm .
1993 50b0790e 2020-09-11 stsp If present, a
1994 50b0790e 2020-09-11 stsp .Xr got.conf 5
1995 50b0790e 2020-09-11 stsp configuration file located in the root directory of a Git repository
1996 50b0790e 2020-09-11 stsp supersedes any relevant settings in Git's
1997 257add31 2020-09-09 stsp .Pa config
1998 257add31 2020-09-09 stsp file.
1999 50b0790e 2020-09-11 stsp .Pp
2000 50b0790e 2020-09-11 stsp .It Pa .got/got.conf
2001 50b0790e 2020-09-11 stsp Worktree-specific configuration settings for
2002 50b0790e 2020-09-11 stsp .Nm .
2003 50b0790e 2020-09-11 stsp If present, a
2004 50b0790e 2020-09-11 stsp .Xr got.conf
2005 50b0790e 2020-09-11 stsp configuration file in the
2006 50b0790e 2020-09-11 stsp .Pa .got
2007 50b0790e 2020-09-11 stsp meta-data directory of a work tree supersedes any relevant settings in
2008 50b0790e 2020-09-11 stsp the repository's
2009 50b0790e 2020-09-11 stsp .Xr got.conf 5
2010 50b0790e 2020-09-11 stsp configuration file and Git's
2011 50b0790e 2020-09-11 stsp .Pa config
2012 50b0790e 2020-09-11 stsp file.
2013 257add31 2020-09-09 stsp .El
2014 5c860e29 2018-03-12 stsp .Sh EXIT STATUS
2015 5c860e29 2018-03-12 stsp .Ex -std got
2016 97925469 2018-03-17 stsp .Sh EXAMPLES
2017 fa6e0e48 2019-05-23 stsp Clone an existing Git repository for use with
2018 fa6e0e48 2019-05-23 stsp .Nm .
2019 fd039d72 2020-03-18 stsp .Pp
2020 fd039d72 2020-03-18 stsp .Dl $ cd /var/git/
2021 fd039d72 2020-03-18 stsp .Dl $ got clone ssh://git@github.com/openbsd/src.git
2022 fd039d72 2020-03-18 stsp .Pp
2023 fd039d72 2020-03-18 stsp Use of HTTP URLs currently requires
2024 fa6e0e48 2019-05-23 stsp .Xr git 1 :
2025 d83d9d5c 2019-05-13 stsp .Pp
2026 fa6e0e48 2019-05-23 stsp .Dl $ cd /var/git/
2027 fa6e0e48 2019-05-23 stsp .Dl $ git clone --bare https://github.com/openbsd/src.git
2028 fa6e0e48 2019-05-23 stsp .Pp
2029 3ce1b845 2019-07-15 stsp Alternatively, for quick and dirty local testing of
2030 3ce1b845 2019-07-15 stsp .Nm
2031 3ce1b845 2019-07-15 stsp a new Git repository could be created and populated with files,
2032 3ce1b845 2019-07-15 stsp e.g. from a temporary CVS checkout located at
2033 3ce1b845 2019-07-15 stsp .Pa /tmp/src :
2034 fa6e0e48 2019-05-23 stsp .Pp
2035 3ce1b845 2019-07-15 stsp .Dl $ got init /var/git/src.git
2036 2930ef13 2019-07-15 stsp .Dl $ got import -r /var/git/src.git -I CVS -I obj /tmp/src
2037 3ce1b845 2019-07-15 stsp .Pp
2038 3ce1b845 2019-07-15 stsp Check out a work tree from the Git repository to /usr/src:
2039 3ce1b845 2019-07-15 stsp .Pp
2040 fa6e0e48 2019-05-23 stsp .Dl $ got checkout /var/git/src.git /usr/src
2041 fa6e0e48 2019-05-23 stsp .Pp
2042 e70c17ce 2019-05-22 stsp View local changes in a work tree directory:
2043 e70c17ce 2019-05-22 stsp .Pp
2044 e70c17ce 2019-05-22 stsp .Dl $ got diff | less
2045 33aa809d 2019-08-08 stsp .Pp
2046 081470ac 2020-08-13 stsp In a work tree, display files in a potentially problematic state:
2047 081470ac 2020-08-13 stsp .Pp
2048 081470ac 2020-08-13 stsp .Dl $ got status -s 'C!~?'
2049 081470ac 2020-08-13 stsp .Pp
2050 33aa809d 2019-08-08 stsp Interactively revert selected local changes in a work tree directory:
2051 e70c17ce 2019-05-22 stsp .Pp
2052 33aa809d 2019-08-08 stsp .Dl $ got revert -p -R\ .
2053 33aa809d 2019-08-08 stsp .Pp
2054 e70c17ce 2019-05-22 stsp In a work tree or a git repository directory, list all branch references:
2055 e70c17ce 2019-05-22 stsp .Pp
2056 4e759de4 2019-06-26 stsp .Dl $ got branch -l
2057 e70c17ce 2019-05-22 stsp .Pp
2058 fa6e0e48 2019-05-23 stsp In a work tree or a git repository directory, create a new branch called
2059 e70c17ce 2019-05-22 stsp .Dq unified-buffer-cache
2060 d83d9d5c 2019-05-13 stsp which is forked off the
2061 d83d9d5c 2019-05-13 stsp .Dq master
2062 d83d9d5c 2019-05-13 stsp branch:
2063 d83d9d5c 2019-05-13 stsp .Pp
2064 4e759de4 2019-06-26 stsp .Dl $ got branch unified-buffer-cache master
2065 e70c17ce 2019-05-22 stsp .Pp
2066 e70c17ce 2019-05-22 stsp Switch an existing work tree to the branch
2067 e70c17ce 2019-05-22 stsp .Dq unified-buffer-cache .
2068 e70c17ce 2019-05-22 stsp Local changes in the work tree will be preserved and merged if necessary:
2069 e70c17ce 2019-05-22 stsp .Pp
2070 e70c17ce 2019-05-22 stsp .Dl $ got update -b unified-buffer-cache
2071 e70c17ce 2019-05-22 stsp .Pp
2072 fa6e0e48 2019-05-23 stsp Create a new commit from local changes in a work tree directory.
2073 fa6e0e48 2019-05-23 stsp This new commit will become the head commit of the work tree's current branch:
2074 fa6e0e48 2019-05-23 stsp .Pp
2075 fa6e0e48 2019-05-23 stsp .Dl $ got commit
2076 fa6e0e48 2019-05-23 stsp .Pp
2077 fa6e0e48 2019-05-23 stsp In a work tree or a git repository directory, view changes committed in
2078 fa6e0e48 2019-05-23 stsp the 3 most recent commits to the work tree's branch, or the branch resolved
2079 fa6e0e48 2019-05-23 stsp via the repository's HEAD reference, respectively:
2080 fa6e0e48 2019-05-23 stsp .Pp
2081 48c8c60d 2020-01-27 stsp .Dl $ got log -p -l 3
2082 04e9dcf3 2020-04-18 stsp .Pp
2083 3d0ac559 2020-04-18 stsp As above, but display changes in the order in which
2084 04e9dcf3 2020-04-18 stsp .Xr patch 1
2085 04e9dcf3 2020-04-18 stsp could apply them in sequence:
2086 5b666081 2020-02-24 stsp .Pp
2087 04e9dcf3 2020-04-18 stsp .Dl $ got log -p -l 3 -R
2088 04e9dcf3 2020-04-18 stsp .Pp
2089 5b666081 2020-02-24 stsp In a work tree or a git repository directory, log the history of a subdirectory:
2090 5b666081 2020-02-24 stsp .Pp
2091 5b666081 2020-02-24 stsp .Dl $ got log sys/uvm
2092 5b666081 2020-02-24 stsp .Pp
2093 5b666081 2020-02-24 stsp While operating inside a work tree, paths are specified relative to the current
2094 5b666081 2020-02-24 stsp working directory, so this command will log the subdirectory
2095 5b666081 2020-02-24 stsp .Pa sys/uvm :
2096 fa6e0e48 2019-05-23 stsp .Pp
2097 cf07f22b 2020-07-25 stsp .Dl $ cd sys/uvm && got log\ .
2098 5b666081 2020-02-24 stsp .Pp
2099 5b666081 2020-02-24 stsp And this command has the same effect:
2100 5b666081 2020-02-24 stsp .Pp
2101 5b666081 2020-02-24 stsp .Dl $ cd sys/dev/usb && got log ../../uvm
2102 5b666081 2020-02-24 stsp .Pp
2103 b2118c49 2020-07-28 stsp And this command displays work tree meta-data about all tracked files:
2104 b2118c49 2020-07-28 stsp .Pp
2105 b2118c49 2020-07-28 stsp .Dl $ cd /usr/src
2106 b2118c49 2020-07-28 stsp .Dl $ got info\ . | less
2107 b2118c49 2020-07-28 stsp .Pp
2108 e70c17ce 2019-05-22 stsp Add new files and remove obsolete files in a work tree directory:
2109 e70c17ce 2019-05-22 stsp .Pp
2110 fa6e0e48 2019-05-23 stsp .Dl $ got add sys/uvm/uvm_ubc.c
2111 86d25a1b 2019-07-11 stsp .Dl $ got remove sys/uvm/uvm_vnode.c
2112 e70c17ce 2019-05-22 stsp .Pp
2113 e70c17ce 2019-05-22 stsp Create a new commit from local changes in a work tree directory
2114 e70c17ce 2019-05-22 stsp with a pre-defined log message.
2115 e70c17ce 2019-05-22 stsp .Pp
2116 e70c17ce 2019-05-22 stsp .Dl $ got commit -m 'unify the buffer cache'
2117 95fc3404 2019-07-15 stsp .Pp
2118 bcbc2272 2020-05-20 stsp Alternatively, create a new commit from local changes in a work tree
2119 bcbc2272 2020-05-20 stsp directory with a log message that has been prepared in the file
2120 bcbc2272 2020-05-20 stsp .Pa /tmp/msg .
2121 bcbc2272 2020-05-20 stsp If
2122 bcbc2272 2020-05-20 stsp .Xr vi 1
2123 bcbc2272 2020-05-20 stsp is set as the
2124 bcbc2272 2020-05-20 stsp .Ev EDITOR ,
2125 bcbc2272 2020-05-20 stsp .Pa /tmp/msg
2126 bcbc2272 2020-05-20 stsp can be read into the buffer for review:
2127 bcbc2272 2020-05-20 stsp .Pp
2128 bcbc2272 2020-05-20 stsp .Dl $ got commit
2129 bcbc2272 2020-05-20 stsp .Dl :r /tmp/msg
2130 bcbc2272 2020-05-20 stsp .Pp
2131 95fc3404 2019-07-15 stsp Update any work tree checked out from the
2132 95fc3404 2019-07-15 stsp .Dq unified-buffer-cache
2133 95fc3404 2019-07-15 stsp branch to the latest commit on this branch:
2134 95fc3404 2019-07-15 stsp .Pp
2135 95fc3404 2019-07-15 stsp .Dl $ got update
2136 ac90e726 2019-07-15 stsp .Pp
2137 c991308a 2019-07-15 stsp Roll file content on the unified-buffer-cache branch back by one commit,
2138 c991308a 2019-07-15 stsp and then fetch the rolled-back change into the work tree as a local change
2139 ac90e726 2019-07-15 stsp to be amended and perhaps committed again:
2140 e70c17ce 2019-05-22 stsp .Pp
2141 ac90e726 2019-07-15 stsp .Dl $ got backout unified-buffer-cache
2142 ac90e726 2019-07-15 stsp .Dl $ got commit -m 'roll back previous'
2143 59d52b88 2019-07-15 stsp .Dl $ # now back out the previous backout :-)
2144 ac90e726 2019-07-15 stsp .Dl $ got backout unified-buffer-cache
2145 ac90e726 2019-07-15 stsp .Pp
2146 469dd726 2020-03-20 stsp Fetch new upstream commits into the local repository's
2147 469dd726 2020-03-20 stsp .Dq origin/master
2148 469dd726 2020-03-20 stsp branch:
2149 fa6e0e48 2019-05-23 stsp .Pp
2150 469dd726 2020-03-20 stsp .Dl $ cd /usr/src
2151 469dd726 2020-03-20 stsp .Dl $ got fetch
2152 469dd726 2020-03-20 stsp .Pp
2153 469dd726 2020-03-20 stsp In a repository created with a HTTP URL and
2154 469dd726 2020-03-20 stsp .Cm git clone --bare
2155 469dd726 2020-03-20 stsp the
2156 469dd726 2020-03-20 stsp .Xr git-fetch 1
2157 469dd726 2020-03-20 stsp command must be used instead:
2158 469dd726 2020-03-20 stsp .Pp
2159 fa6e0e48 2019-05-23 stsp .Dl $ cd /var/git/src.git
2160 469dd726 2020-03-20 stsp .Dl $ git fetch origin master:refs/remotes/origin/master
2161 fa6e0e48 2019-05-23 stsp .Pp
2162 469dd726 2020-03-20 stsp Rebase the local
2163 469dd726 2020-03-20 stsp .Dq master
2164 469dd726 2020-03-20 stsp branch to merge the new changes that are now visible on the
2165 469dd726 2020-03-20 stsp .Dq origin/master
2166 469dd726 2020-03-20 stsp branch:
2167 469dd726 2020-03-20 stsp .Pp
2168 469dd726 2020-03-20 stsp .Dl $ cd /usr/src
2169 469dd726 2020-03-20 stsp .Dl $ got update -b origin/master
2170 469dd726 2020-03-20 stsp .Dl $ got rebase master
2171 469dd726 2020-03-20 stsp .Pp
2172 fa6e0e48 2019-05-23 stsp Rebase the
2173 fa6e0e48 2019-05-23 stsp .Dq unified-buffer-cache
2174 fa6e0e48 2019-05-23 stsp branch on top of the new head commit of the
2175 fa6e0e48 2019-05-23 stsp .Dq master
2176 fa6e0e48 2019-05-23 stsp branch.
2177 fa6e0e48 2019-05-23 stsp .Pp
2178 818c7501 2019-07-11 stsp .Dl $ got update -b master
2179 818c7501 2019-07-11 stsp .Dl $ got rebase unified-buffer-cache
2180 7d7ffedb 2019-07-14 stsp .Pp
2181 7d7ffedb 2019-07-14 stsp Create a patch from all changes on the unified-buffer-cache branch.
2182 1dd86744 2019-08-12 anthony The patch can be mailed out for review and applied to
2183 1dd86744 2019-08-12 anthony .Ox Ns 's
2184 1dd86744 2019-08-12 anthony CVS tree:
2185 7d7ffedb 2019-07-14 stsp .Pp
2186 7d7ffedb 2019-07-14 stsp .Dl $ got diff master unified-buffer-cache > /tmp/ubc.diff
2187 7d7ffedb 2019-07-14 stsp .Pp
2188 0ebf8283 2019-07-24 stsp Edit the entire commit history of the
2189 0ebf8283 2019-07-24 stsp .Dq unified-buffer-cache
2190 0ebf8283 2019-07-24 stsp branch:
2191 0ebf8283 2019-07-24 stsp .Pp
2192 0ebf8283 2019-07-24 stsp .Dl $ got update -b unified-buffer-cache
2193 0ebf8283 2019-07-24 stsp .Dl $ got update -c master
2194 0ebf8283 2019-07-24 stsp .Dl $ got histedit
2195 bf390dec 2020-03-20 stsp .Pp
2196 bf390dec 2020-03-20 stsp In order to merge changes committed to the
2197 bf390dec 2020-03-20 stsp .Dq unified-buffer-cache
2198 bf390dec 2020-03-20 stsp branch back into the
2199 bf390dec 2020-03-20 stsp .Dq master
2200 bf390dec 2020-03-20 stsp branch, the
2201 bf390dec 2020-03-20 stsp .Dq unified-buffer-cache
2202 bf390dec 2020-03-20 stsp branch must first be rebased onto the
2203 bf390dec 2020-03-20 stsp .Dq master
2204 bf390dec 2020-03-20 stsp branch:
2205 bf390dec 2020-03-20 stsp .Pp
2206 bf390dec 2020-03-20 stsp .Dl $ got update -b master
2207 bf390dec 2020-03-20 stsp .Dl $ got rebase unified-buffer-cache
2208 bf390dec 2020-03-20 stsp .Pp
2209 bf390dec 2020-03-20 stsp Changes on the
2210 bf390dec 2020-03-20 stsp .Dq unified-buffer-cache
2211 bf390dec 2020-03-20 stsp branch can now be made visible on the
2212 bf390dec 2020-03-20 stsp .Dq master
2213 bf390dec 2020-03-20 stsp branch with
2214 bf390dec 2020-03-20 stsp .Cm got integrate .
2215 bf390dec 2020-03-20 stsp Because the rebase operation switched the work tree to the
2216 bf390dec 2020-03-20 stsp .Dq unified-buffer-cache
2217 bf390dec 2020-03-20 stsp branch, the work tree must be switched back to the
2218 bf390dec 2020-03-20 stsp .Dq master
2219 bf390dec 2020-03-20 stsp branch before the
2220 bf390dec 2020-03-20 stsp .Dq unified-buffer-cache
2221 bf390dec 2020-03-20 stsp branch can be integrated into
2222 bf390dec 2020-03-20 stsp .Dq master :
2223 ff2cf171 2019-07-28 stsp .Pp
2224 bf390dec 2020-03-20 stsp .Dl $ got update -b master
2225 bf390dec 2020-03-20 stsp .Dl $ got integrate unified-buffer-cache
2226 469dd726 2020-03-20 stsp .Pp
2227 469dd726 2020-03-20 stsp Additional steps may be necessary if local changes need to be pushed back
2228 7b3fde24 2019-07-28 stsp to the remote repository, which currently requires
2229 7b3fde24 2019-07-28 stsp .Cm git push .
2230 ff2cf171 2019-07-28 stsp Before working against existing branches in a repository cloned with
2231 469dd726 2020-03-20 stsp .Cm git clone --bare
2232 7848a0e1 2020-03-19 stsp instead of
2233 7848a0e1 2020-03-19 stsp .Cm got clone ,
2234 ff2cf171 2019-07-28 stsp a Git
2235 ff2cf171 2019-07-28 stsp .Dq refspec
2236 ff2cf171 2019-07-28 stsp must be configured to map all references in the remote repository
2237 ff2cf171 2019-07-28 stsp into the
2238 ff2cf171 2019-07-28 stsp .Dq refs/remotes
2239 ff2cf171 2019-07-28 stsp namespace of the local repository.
2240 ff2cf171 2019-07-28 stsp This can achieved by setting Git's
2241 ff2cf171 2019-07-28 stsp .Pa remote.origin.fetch
2242 ff2cf171 2019-07-28 stsp configuration variable to the value
2243 ff2cf171 2019-07-28 stsp .Dq +refs/heads/*:refs/remotes/origin/*
2244 ff2cf171 2019-07-28 stsp with the
2245 ff2cf171 2019-07-28 stsp .Cm git config
2246 ff2cf171 2019-07-28 stsp command:
2247 ff2cf171 2019-07-28 stsp .Pp
2248 ff2cf171 2019-07-28 stsp .Dl $ cd /var/git/repo
2249 ff2cf171 2019-07-28 stsp .Dl $ git config remote.origin.fetch '+refs/heads/*:refs/remotes/origin/*'
2250 eac81709 2020-03-21 stsp .Pp
2251 469dd726 2020-03-20 stsp Additionally, the
2252 469dd726 2020-03-20 stsp .Dq mirror
2253 469dd726 2020-03-20 stsp option must be disabled:
2254 ff2cf171 2019-07-28 stsp .Pp
2255 469dd726 2020-03-20 stsp .Dl $ cd /var/git/repo
2256 469dd726 2020-03-20 stsp .Dl $ git config remote.origin.mirror false
2257 469dd726 2020-03-20 stsp .Pp
2258 ff2cf171 2019-07-28 stsp Alternatively, the following
2259 469dd726 2020-03-20 stsp .Xr git-fetch 1
2260 ff2cf171 2019-07-28 stsp configuration item can be added manually to the Git repository's
2261 ff2cf171 2019-07-28 stsp .Pa config
2262 ff2cf171 2019-07-28 stsp file:
2263 0ebf8283 2019-07-24 stsp .Pp
2264 ff2cf171 2019-07-28 stsp .Dl [remote "origin"]
2265 ff2cf171 2019-07-28 stsp .Dl url = ...
2266 ff2cf171 2019-07-28 stsp .Dl fetch = +refs/heads/*:refs/remotes/origin/*
2267 469dd726 2020-03-20 stsp .Dl mirror = false
2268 ff2cf171 2019-07-28 stsp .Pp
2269 fe307c9b 2019-07-28 stsp This configuration leaves the local repository's
2270 ff2cf171 2019-07-28 stsp .Dq refs/heads
2271 ff2cf171 2019-07-28 stsp namespace free for use by local branches checked out with
2272 ff2cf171 2019-07-28 stsp .Cm got checkout
2273 ff2cf171 2019-07-28 stsp and, if needed, created with
2274 ff2cf171 2019-07-28 stsp .Cm got branch .
2275 ff2cf171 2019-07-28 stsp .Pp
2276 ff2cf171 2019-07-28 stsp Branches in the
2277 ff2cf171 2019-07-28 stsp .Dq remotes/origin
2278 469dd726 2020-03-20 stsp namespace can now be updated with incoming changes from the remote
2279 ff2cf171 2019-07-28 stsp repository with
2280 469dd726 2020-03-20 stsp .Cm got fetch
2281 469dd726 2020-03-20 stsp or
2282 469dd726 2020-03-20 stsp .Xr git-fetch 1
2283 469dd726 2020-03-20 stsp without extra command line arguments:
2284 ff2cf171 2019-07-28 stsp .Pp
2285 ff2cf171 2019-07-28 stsp .Dl $ cd /var/git/repo
2286 469dd726 2020-03-20 stsp .Dl $ git fetch
2287 ff2cf171 2019-07-28 stsp .Pp
2288 7b0db533 2020-02-04 stsp To make changes fetched from the remote repository appear on the
2289 ff2cf171 2019-07-28 stsp .Dq master
2290 7b0db533 2020-02-04 stsp branch, the
2291 ff2cf171 2019-07-28 stsp .Dq master
2292 ff2cf171 2019-07-28 stsp branch must be rebased onto the
2293 ff2cf171 2019-07-28 stsp .Dq origin/master
2294 7b0db533 2020-02-04 stsp branch.
2295 7b0db533 2020-02-04 stsp This will also merge local changes, if any, with the incoming changes:
2296 ff2cf171 2019-07-28 stsp .Pp
2297 ff2cf171 2019-07-28 stsp .Dl $ got update -b origin/master
2298 ff2cf171 2019-07-28 stsp .Dl $ got rebase master
2299 083957f4 2020-02-24 stsp .Pp
2300 083957f4 2020-02-24 stsp On the
2301 083957f4 2020-02-24 stsp .Dq master
2302 083957f4 2020-02-24 stsp branch, log messages for local changes can now be amended with
2303 083957f4 2020-02-24 stsp .Dq OK
2304 083957f4 2020-02-24 stsp by other developers and any other important new information:
2305 ff2cf171 2019-07-28 stsp .Pp
2306 083957f4 2020-02-24 stsp .Dl $ got update -c origin/master
2307 083957f4 2020-02-24 stsp .Dl $ got histedit -m
2308 083957f4 2020-02-24 stsp .Pp
2309 7b0db533 2020-02-04 stsp Local changes on the
2310 ff2cf171 2019-07-28 stsp .Dq master
2311 ff2cf171 2019-07-28 stsp branch can then be pushed to the remote
2312 ff2cf171 2019-07-28 stsp repository with
2313 ff2cf171 2019-07-28 stsp .Cm git push :
2314 ff2cf171 2019-07-28 stsp .Pp
2315 ff2cf171 2019-07-28 stsp .Dl $ cd /var/git/repo
2316 ff2cf171 2019-07-28 stsp .Dl $ git push origin master
2317 5c860e29 2018-03-12 stsp .Sh SEE ALSO
2318 2312fc47 2019-07-15 stsp .Xr tog 1 ,
2319 2312fc47 2019-07-15 stsp .Xr git-repository 5 ,
2320 257add31 2020-09-09 stsp .Xr got-worktree 5 ,
2321 257add31 2020-09-09 stsp .Xr got.conf 5
2322 1a208aaf 2018-04-01 stsp .Sh AUTHORS
2323 1a208aaf 2018-04-01 stsp .An Stefan Sperling Aq Mt stsp@openbsd.org
2324 1a208aaf 2018-04-01 stsp .An Martin Pieuchot Aq Mt mpi@openbsd.org
2325 bc3056e3 2019-08-18 stsp .An Joshua Stein Aq Mt jcs@openbsd.org
2326 83b416ed 2020-03-18 stsp .An Ori Bernstein Aq Mt ori@openbsd.org
2327 fa6e0e48 2019-05-23 stsp .Sh CAVEATS
2328 fa6e0e48 2019-05-23 stsp .Nm
2329 cc63216e 2020-12-26 stsp is a work-in-progress and some features remain to be implemented.
2330 cc63216e 2020-12-26 stsp
2331 fa6e0e48 2019-05-23 stsp At present, the user has to fall back on
2332 fa6e0e48 2019-05-23 stsp .Xr git 1
2333 cc63216e 2020-12-26 stsp to perform some tasks.
2334 cc63216e 2020-12-26 stsp In particular:
2335 cc63216e 2020-12-26 stsp .Bl -bullet
2336 cc63216e 2020-12-26 stsp .It
2337 cc63216e 2020-12-26 stsp Reading from remote repositories over HTTP or HTTPS protocols requires
2338 cc63216e 2020-12-26 stsp .Xr git-clone 1
2339 cc63216e 2020-12-26 stsp and
2340 cc63216e 2020-12-26 stsp .Xr git-fetch 1 .
2341 cc63216e 2020-12-26 stsp .It
2342 cc63216e 2020-12-26 stsp Writing to remote repositories, over any protocol, requires
2343 cc63216e 2020-12-26 stsp .Xr git-push 1 .
2344 cc63216e 2020-12-26 stsp .It
2345 cc63216e 2020-12-26 stsp Packing repositories, which reduces disk space consumption and improves
2346 cc63216e 2020-12-26 stsp read-access performance, requires
2347 cc63216e 2020-12-26 stsp .Xr git-repack 1 .
2348 cc63216e 2020-12-26 stsp .It
2349 cc63216e 2020-12-26 stsp Exporting data from repositories requires
2350 cc63216e 2020-12-26 stsp .Xr git-fast-export 1 .
2351 cc63216e 2020-12-26 stsp .It
2352 cc63216e 2020-12-26 stsp Importing data into repositories requires
2353 cc63216e 2020-12-26 stsp .Xr git-fast-import 1 .
2354 cc63216e 2020-12-26 stsp .It
2355 cc63216e 2020-12-26 stsp Reducing the size of repositories by removing redundant or unreferenced
2356 cc63216e 2020-12-26 stsp data requires
2357 cc63216e 2020-12-26 stsp .Xr git-gc 1 .
2358 cc63216e 2020-12-26 stsp .It
2359 cc63216e 2020-12-26 stsp The creation of merge commits, i.e. commits with two or more parent commits,
2360 cc63216e 2020-12-26 stsp requires
2361 cc63216e 2020-12-26 stsp .Xr git-merge 1 .
2362 cc63216e 2020-12-26 stsp .It
2363 cc63216e 2020-12-26 stsp In situations where files or directories were moved around
2364 cc63216e 2020-12-26 stsp .Cm got
2365 cc63216e 2020-12-26 stsp will not automatically merge changes to new locations and
2366 cc63216e 2020-12-26 stsp .Xr git 1
2367 cc63216e 2020-12-26 stsp will usually produce better results.
2368 cc63216e 2020-12-26 stsp .El