2 5c860e29 2018-03-12 stsp .\" Copyright (c) 2017 Martin Pieuchot
3 5aa81393 2020-01-06 stsp .\" Copyright (c) 2018, 2019, 2020 Stefan Sperling
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.
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.
17 5c860e29 2018-03-12 stsp .Dd $Mdocdate$
22 8e13c46f 2019-08-05 stsp .Nd Game of Trees
23 5c860e29 2018-03-12 stsp .Sh SYNOPSIS
27 5c860e29 2018-03-12 stsp .Op Ar arg ...
28 5c860e29 2018-03-12 stsp .Sh DESCRIPTION
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 .
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.
42 285dc8a4 2018-03-13 stsp Files managed by
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 .
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
56 fef8a0d3 2019-08-04 stsp Display usage information and exit immediately.
57 1795b260 2021-04-02 kn .It Fl V , -version
58 53ccebc2 2019-07-30 stsp Display program version and exit immediately.
61 38e11793 2018-06-13 stsp The commands for
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 .
70 3ce1b845 2019-07-15 stsp .Cm got init ,
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.
77 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
78 d912d125 2021-11-04 thomas .Dl Pq alias: Cm im
79 3ce1b845 2019-07-15 stsp Create an initial commit in a repository from the file hierarchy
80 3ce1b845 2019-07-15 stsp within the specified
81 3ce1b845 2019-07-15 stsp .Ar directory .
82 3ce1b845 2019-07-15 stsp The created commit will not have any parent commits, i.e. it will be a
83 3ce1b845 2019-07-15 stsp root commit.
84 3ce1b845 2019-07-15 stsp Also create a new reference which provides a branch name for the newly
85 3ce1b845 2019-07-15 stsp created commit.
86 21a44f98 2019-07-15 stsp Show the path of each imported file to indicate progress.
89 21a44f98 2019-07-15 stsp .Cm got import
90 21a44f98 2019-07-15 stsp command requires the
91 21a44f98 2019-07-15 stsp .Ev GOT_AUTHOR
92 aba9c984 2019-09-08 stsp environment variable to be set,
93 257add31 2020-09-09 stsp unless an author has been configured in
94 257add31 2020-09-09 stsp .Xr got.conf 5
96 aba9c984 2019-09-08 stsp .Dv user.name
98 709ae9eb 2019-09-08 stsp .Dv user.email
99 709ae9eb 2019-09-08 stsp configuration settings can be obtained from the repository's
100 aba9c984 2019-09-08 stsp .Pa .git/config
101 c9956ddf 2019-09-08 stsp file or from Git's global
102 c9956ddf 2019-09-08 stsp .Pa ~/.gitconfig
103 c9956ddf 2019-09-08 stsp configuration file.
105 3ce1b845 2019-07-15 stsp The options for
106 3ce1b845 2019-07-15 stsp .Cm got import
107 3ce1b845 2019-07-15 stsp are as follows:
108 3ce1b845 2019-07-15 stsp .Bl -tag -width Ds
109 3ce1b845 2019-07-15 stsp .It Fl b Ar branch
110 3ce1b845 2019-07-15 stsp Create the specified
112 3ce1b845 2019-07-15 stsp instead of creating the default branch
114 3ce1b845 2019-07-15 stsp Use of this option is required if the
116 3ce1b845 2019-07-15 stsp branch already exists.
117 3ce1b845 2019-07-15 stsp .It Fl m Ar message
118 3ce1b845 2019-07-15 stsp Use the specified log message when creating the new commit.
119 3ce1b845 2019-07-15 stsp Without the
122 3ce1b845 2019-07-15 stsp .Cm got import
123 3ce1b845 2019-07-15 stsp opens a temporary file in an editor where a log message can be written.
124 3ce1b845 2019-07-15 stsp .It Fl r Ar repository-path
125 3ce1b845 2019-07-15 stsp Use the repository at the specified path.
126 3ce1b845 2019-07-15 stsp If not specified, assume the repository is located at or above the current
127 3ce1b845 2019-07-15 stsp working directory.
128 3ce1b845 2019-07-15 stsp .It Fl I Ar pattern
129 3ce1b845 2019-07-15 stsp Ignore files or directories with a name which matches the specified
130 3ce1b845 2019-07-15 stsp .Ar pattern .
131 3ce1b845 2019-07-15 stsp This option may be specified multiple times to build a list of ignore patterns.
133 3ce1b845 2019-07-15 stsp .Ar pattern
134 3ce1b845 2019-07-15 stsp follows the globbing rules documented in
135 3ce1b845 2019-07-15 stsp .Xr glob 7 .
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 d912d125 2021-11-04 thomas .Dl Pq alias: Cm cl
140 2ab43947 2020-03-18 stsp Clone a Git repository at the specified
141 2ab43947 2020-03-18 stsp .Ar repository-URL
142 2ab43947 2020-03-18 stsp into the specified
143 3493b628 2020-03-20 stsp .Ar directory .
145 3493b628 2020-03-20 stsp .Ar directory
146 4b06140e 2022-03-22 thomas is specified, the directory name will be derived from the name of the
147 2ab43947 2020-03-18 stsp cloned repository.
148 2ab43947 2020-03-18 stsp .Cm got clone
149 2ab43947 2020-03-18 stsp will refuse to run if the
150 3493b628 2020-03-20 stsp .Ar directory
151 2ab43947 2020-03-18 stsp already exists.
154 2ab43947 2020-03-18 stsp .Ar repository-URL
155 619eb6dd 2020-03-20 stsp specifies a protocol scheme, a server hostname, an optional port number
156 619eb6dd 2020-03-20 stsp separated from the hostname by a colon, and a path to the repository on
157 619eb6dd 2020-03-20 stsp the server:
158 619eb6dd 2020-03-20 stsp .Lk scheme://hostname:port/path/to/repository
160 2ab43947 2020-03-18 stsp The following protocol schemes are supported:
161 2ab43947 2020-03-18 stsp .Bl -tag -width git+ssh
163 2ab43947 2020-03-18 stsp The Git protocol as implemented by the
164 2ab43947 2020-03-18 stsp .Xr git-daemon 1
166 10c073e7 2020-03-20 stsp Use of this protocol is discouraged since it supports neither authentication
167 10c073e7 2020-03-20 stsp nor encryption.
168 2ab43947 2020-03-18 stsp .It git+ssh
169 2ab43947 2020-03-18 stsp The Git protocol wrapped in an authenticated and encrypted
172 2ab43947 2020-03-18 stsp With this protocol the hostname may contain an embedded username for
175 2ab43947 2020-03-18 stsp .Mt user@hostname
177 2ab43947 2020-03-18 stsp Short alias for git+ssh.
180 89c3c67b 2020-03-20 stsp Objects in the cloned repository are stored in a pack file which is downloaded
181 89c3c67b 2020-03-20 stsp from the server.
182 89c3c67b 2020-03-20 stsp This pack file will then be indexed to facilitate access to the objects stored
184 89c3c67b 2020-03-20 stsp If any objects in the pack file are stored in deltified form, all deltas will
185 89c3c67b 2020-03-20 stsp be fully resolved in order to compute the ID of such objects.
186 89c3c67b 2020-03-20 stsp This can take some time.
187 010f7279 2020-03-20 stsp More details about the pack file format are documented in
188 010f7279 2020-03-20 stsp .Xr git-repository 5 .
190 7848a0e1 2020-03-19 stsp .Cm got clone
191 7848a0e1 2020-03-19 stsp creates a remote repository entry in the
192 257add31 2020-09-09 stsp .Xr got.conf 5
195 257add31 2020-09-09 stsp files of the cloned repository to store the
196 7848a0e1 2020-03-19 stsp .Ar repository-url
200 99495ddb 2021-01-10 stsp .Ar reference
201 132af4a5 2021-01-05 stsp arguments for future use by
202 7848a0e1 2020-03-19 stsp .Cm got fetch
204 7848a0e1 2020-03-19 stsp .Xr git-fetch 1 .
206 2ab43947 2020-03-18 stsp The options for
207 2ab43947 2020-03-18 stsp .Cm got clone
208 2ab43947 2020-03-18 stsp are as follows:
209 2ab43947 2020-03-18 stsp .Bl -tag -width Ds
211 1d4b192f 2020-03-21 stsp Fetch all branches from the remote repository's
212 1d4b192f 2020-03-21 stsp .Dq refs/heads/
213 5aa20203 2021-01-05 stsp reference namespace and set
214 5aa20203 2021-01-05 stsp .Cm fetch-all-branches
215 5aa20203 2021-01-05 stsp in the cloned repository's
216 5aa20203 2021-01-05 stsp .Xr got.conf 5
217 5aa20203 2021-01-05 stsp file for future use by
218 5aa20203 2021-01-05 stsp .Cm got fetch .
219 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
220 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
221 4ba14133 2020-03-20 stsp Cannot be used together with the
224 4ba14133 2020-03-20 stsp .It Fl b Ar branch
225 4ba14133 2020-03-20 stsp Fetch the specified
227 1d4b192f 2020-03-21 stsp from the remote repository's
228 1d4b192f 2020-03-21 stsp .Dq refs/heads/
229 1d4b192f 2020-03-21 stsp reference namespace.
230 4ba14133 2020-03-20 stsp This option may be specified multiple times to build a list of branches
232 4ba14133 2020-03-20 stsp If the branch corresponding to the remote repository's HEAD reference is not
233 4ba14133 2020-03-20 stsp in this list, the cloned repository's HEAD reference will be set to the first
234 4ba14133 2020-03-20 stsp branch which was fetched.
235 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
236 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
237 4ba14133 2020-03-20 stsp Cannot be used together with the
241 a18cccf9 2020-03-21 stsp List branches and tags available for fetching from the remote repository
242 41b0de12 2020-03-21 stsp and exit immediately.
243 41b0de12 2020-03-21 stsp Cannot be used together with any of the other options except
248 469dd726 2020-03-20 stsp Create the cloned repository as a mirror of the original repository.
249 469dd726 2020-03-20 stsp This is useful if the cloned repository will not be used to store
250 bd81cfb7 2020-04-19 stsp locally created commits.
252 469dd726 2020-03-20 stsp The repository's
253 257add31 2020-09-09 stsp .Xr got.conf 5
256 257add31 2020-09-09 stsp files will be set up with the
258 469dd726 2020-03-20 stsp option enabled, such that
259 469dd726 2020-03-20 stsp .Cm got fetch
261 469dd726 2020-03-20 stsp .Xr git-fetch 1
262 bd81cfb7 2020-04-19 stsp will write incoming changes directly to branches in the
263 469dd726 2020-03-20 stsp .Dq refs/heads/
264 469dd726 2020-03-20 stsp reference namespace, rather than to branches in the
265 469dd726 2020-03-20 stsp .Dq refs/remotes/
267 469dd726 2020-03-20 stsp This avoids the usual requirement of having to run
268 469dd726 2020-03-20 stsp .Cm got rebase
270 469dd726 2020-03-20 stsp .Cm got fetch
271 bd81cfb7 2020-04-19 stsp in order to make incoming changes appear on branches in the
272 bd81cfb7 2020-04-19 stsp .Dq refs/heads/
274 bd81cfb7 2020-04-19 stsp But maintaining custom changes in the cloned repository becomes difficult
275 bd81cfb7 2020-04-19 stsp since such changes will be at risk of being discarded whenever incoming
276 498ef124 2020-03-21 stsp changes are fetched.
278 2ab43947 2020-03-18 stsp Suppress progress reporting output.
279 2ab43947 2020-03-18 stsp The same option will be passed to
281 2ab43947 2020-03-18 stsp if applicable.
283 2690194b 2020-03-21 stsp Verbose mode.
285 2690194b 2020-03-21 stsp .Cm got clone
286 2690194b 2020-03-21 stsp to print debugging messages to standard error output.
287 2690194b 2020-03-21 stsp This option will be passed to
289 2ab43947 2020-03-18 stsp if applicable.
290 2ab43947 2020-03-18 stsp Multiple -v options increase the verbosity.
291 2ab43947 2020-03-18 stsp The maximum is 3.
292 0e4002ca 2020-03-21 stsp .It Fl R Ar reference
293 0e4002ca 2020-03-21 stsp In addition to the branches and tags that will be fetched, fetch an arbitrary
294 0e4002ca 2020-03-21 stsp .Ar reference
295 0e4002ca 2020-03-21 stsp from the remote repository's
298 0e4002ca 2020-03-21 stsp This option may be specified multiple times to build a list of additional
299 0e4002ca 2020-03-21 stsp references to fetch.
300 71f12362 2020-03-21 stsp The specified
301 71f12362 2020-03-21 stsp .Ar reference
302 a18cccf9 2020-03-21 stsp may either be a path to a specific reference, or a reference namespace
303 71f12362 2020-03-21 stsp which will cause all references in this namespace to be fetched.
305 71f12362 2020-03-21 stsp Each reference will be mapped into the cloned repository's
306 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
307 0e4002ca 2020-03-21 stsp namespace, unless the
309 0e4002ca 2020-03-21 stsp option is used to mirror references directly into the cloned repository's
313 0e4002ca 2020-03-21 stsp .Cm got clone
314 0e4002ca 2020-03-21 stsp will refuse to fetch references from the remote repository's
315 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
317 0e4002ca 2020-03-21 stsp .Dq refs/got/
321 161728eb 2021-07-24 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 Oo Fl X Oc Op Ar remote-repository
322 d912d125 2021-11-04 thomas .Dl Pq alias: Cm fe
323 7848a0e1 2020-03-19 stsp Fetch new changes from a remote repository.
325 4ba14133 2020-03-20 stsp .Ar remote-repository
326 4ba14133 2020-03-20 stsp is specified,
328 7848a0e1 2020-03-19 stsp will be used.
329 50b0790e 2020-09-11 stsp The remote repository's URL is obtained from the corresponding entry in
330 257add31 2020-09-09 stsp .Xr got.conf 5
333 f8ab0c60 2020-03-20 stsp file of the local repository, as created by
334 7848a0e1 2020-03-19 stsp .Cm got clone .
336 89c3c67b 2020-03-20 stsp New changes will be stored in a separate pack file downloaded from the server.
337 89c3c67b 2020-03-20 stsp Optionally, separate pack files stored in the repository can be combined with
338 89c3c67b 2020-03-20 stsp .Xr git-repack 1 .
340 498ef124 2020-03-21 stsp By default, branch references in the
341 7848a0e1 2020-03-19 stsp .Dq refs/remotes/
342 498ef124 2020-03-21 stsp reference namespace will be updated to point at the newly fetched commits.
344 498ef124 2020-03-21 stsp .Cm got rebase
345 bd81cfb7 2020-04-19 stsp command can then be used to make new changes visible on branches in the
346 7848a0e1 2020-03-19 stsp .Dq refs/heads/
347 bd81cfb7 2020-04-19 stsp namespace, merging incoming changes with the changes on those branches
348 bd81cfb7 2020-04-19 stsp as necessary.
350 498ef124 2020-03-21 stsp If the repository was created as a mirror with
351 4b06140e 2022-03-22 thomas .Cm got clone -m ,
352 498ef124 2020-03-21 stsp then all branches in the
353 469dd726 2020-03-20 stsp .Dq refs/heads/
354 498ef124 2020-03-21 stsp namespace will be updated directly to match the corresponding branches in
355 498ef124 2020-03-21 stsp the remote repository.
356 175367bd 2020-03-20 stsp If those branches contained local commits, these commits will no longer be
357 175367bd 2020-03-20 stsp reachable via a reference and will therefore be at risk of being discarded
358 e6786710 2021-07-03 stsp by Git's garbage collector or
359 e6786710 2021-07-03 stsp .Cm gotadmin cleanup .
360 bd81cfb7 2020-04-19 stsp Maintaining custom changes in a mirror repository is therefore discouraged.
362 db6d8ad8 2020-03-21 stsp In any case, references in the
363 7848a0e1 2020-03-19 stsp .Dq refs/tags/
364 db6d8ad8 2020-03-21 stsp namespace will always be fetched and mapped directly to local references
365 db6d8ad8 2020-03-21 stsp in the same namespace.
367 7848a0e1 2020-03-19 stsp The options for
368 7848a0e1 2020-03-19 stsp .Cm got fetch
369 7848a0e1 2020-03-19 stsp are as follows:
370 7848a0e1 2020-03-19 stsp .Bl -tag -width Ds
372 1d4b192f 2020-03-21 stsp Fetch all branches from the remote repository's
373 1d4b192f 2020-03-21 stsp .Dq refs/heads/
374 1d4b192f 2020-03-21 stsp reference namespace.
375 0c8b29c5 2021-01-05 stsp This option can be enabled by default for specific repositories in
376 0c8b29c5 2021-01-05 stsp .Xr got.conf 5 .
377 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
378 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
379 4ba14133 2020-03-20 stsp Cannot be used together with the
382 4ba14133 2020-03-20 stsp .It Fl b Ar branch
383 4ba14133 2020-03-20 stsp Fetch the specified
385 1d4b192f 2020-03-21 stsp from the remote repository's
386 1d4b192f 2020-03-21 stsp .Dq refs/heads/
387 1d4b192f 2020-03-21 stsp reference namespace.
388 4ba14133 2020-03-20 stsp This option may be specified multiple times to build a list of branches
390 4ba14133 2020-03-20 stsp If this option is not specified, a branch resolved via the remote
391 4ba14133 2020-03-20 stsp repository's HEAD reference will be fetched.
392 4ba14133 2020-03-20 stsp Cannot be used together with the
396 f21ec2f0 2020-03-21 stsp Delete branches and tags from the local repository which are no longer
397 f21ec2f0 2020-03-21 stsp present in the remote repository.
398 f21ec2f0 2020-03-21 stsp Only references are deleted.
399 239821eb 2020-03-21 stsp Any commit, tree, tag, and blob objects belonging to deleted branches or
400 f21ec2f0 2020-03-21 stsp tags remain in the repository and may be removed separately with
401 e6786710 2021-07-03 stsp Git's garbage collector or
402 e6786710 2021-07-03 stsp .Cm gotadmin cleanup .
404 41b0de12 2020-03-21 stsp List branches and tags available for fetching from the remote repository
405 41b0de12 2020-03-21 stsp and exit immediately.
406 41b0de12 2020-03-21 stsp Cannot be used together with any of the other options except
412 db6d8ad8 2020-03-21 stsp Allow existing references in the
413 db6d8ad8 2020-03-21 stsp .Dq refs/tags
414 db6d8ad8 2020-03-21 stsp namespace to be updated if they have changed on the server.
415 db6d8ad8 2020-03-21 stsp If not specified, only new tag references will be created.
416 7848a0e1 2020-03-19 stsp .It Fl r Ar repository-path
417 7848a0e1 2020-03-19 stsp Use the repository at the specified path.
418 7848a0e1 2020-03-19 stsp If not specified, assume the repository is located at or above the current
419 7848a0e1 2020-03-19 stsp working directory.
420 7848a0e1 2020-03-19 stsp If this directory is a
422 7848a0e1 2020-03-19 stsp work tree, use the repository path associated with this work tree.
424 7848a0e1 2020-03-19 stsp Suppress progress reporting output.
425 7848a0e1 2020-03-19 stsp The same option will be passed to
427 7848a0e1 2020-03-19 stsp if applicable.
429 2690194b 2020-03-21 stsp Verbose mode.
431 2690194b 2020-03-21 stsp .Cm got fetch
432 2690194b 2020-03-21 stsp to print debugging messages to standard error output.
433 7848a0e1 2020-03-19 stsp The same option will be passed to
435 7848a0e1 2020-03-19 stsp if applicable.
436 7848a0e1 2020-03-19 stsp Multiple -v options increase the verbosity.
437 7848a0e1 2020-03-19 stsp The maximum is 3.
438 0e4002ca 2020-03-21 stsp .It Fl R Ar reference
439 0e4002ca 2020-03-21 stsp In addition to the branches and tags that will be fetched, fetch an arbitrary
440 0e4002ca 2020-03-21 stsp .Ar reference
441 0e4002ca 2020-03-21 stsp from the remote repository's
444 0e4002ca 2020-03-21 stsp This option may be specified multiple times to build a list of additional
445 0e4002ca 2020-03-21 stsp references to fetch.
446 71f12362 2020-03-21 stsp The specified
447 71f12362 2020-03-21 stsp .Ar reference
448 a18cccf9 2020-03-21 stsp may either be a path to a specific reference, or a reference namespace
449 71f12362 2020-03-21 stsp which will cause all references in this namespace to be fetched.
451 0e4002ca 2020-03-21 stsp Each reference will be mapped into the local repository's
452 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
453 0e4002ca 2020-03-21 stsp namespace, unless the local repository was created as a mirror with
454 a18cccf9 2020-03-21 stsp .Cm got clone -m
455 a18cccf9 2020-03-21 stsp in which case references will be mapped directly into the local repository's
459 bd81cfb7 2020-04-19 stsp Once a reference has been fetched, a branch based on it can be created with
460 0e4002ca 2020-03-21 stsp .Cm got branch
463 0e4002ca 2020-03-21 stsp .Cm got fetch
464 0e4002ca 2020-03-21 stsp will refuse to fetch references from the remote repository's
465 0e4002ca 2020-03-21 stsp .Dq refs/remotes/
467 0e4002ca 2020-03-21 stsp .Dq refs/got/
470 161728eb 2021-07-24 stsp Delete all references which correspond to a particular
471 161728eb 2021-07-24 stsp .Ar remote-repository
472 161728eb 2021-07-24 stsp instead of fetching new changes.
473 161728eb 2021-07-24 stsp This can be useful when a remote repository is being removed from
474 161728eb 2021-07-24 stsp .Xr got.conf 5 .
479 161728eb 2021-07-24 stsp .Ar remote-repository
480 161728eb 2021-07-24 stsp argument is mandatory and no other options except
485 161728eb 2021-07-24 stsp are allowed.
487 161728eb 2021-07-24 stsp Only references are deleted.
488 161728eb 2021-07-24 stsp Any commit, tree, tag, and blob objects fetched from a remote repository
489 161728eb 2021-07-24 stsp will generally be stored in pack files and may be removed separately with
490 161728eb 2021-07-24 stsp .Xr git-repack 1
491 161728eb 2021-07-24 stsp and Git's garbage collector.
494 4ad4a1ec 2021-09-13 tracey .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 Oo Fl q Oc Ar repository-path Op Ar work-tree-path
495 d912d125 2021-11-04 thomas .Dl Pq alias: Cm co
496 0bb8a95e 2018-03-12 stsp Copy files from a repository into a new work tree.
497 bb51a5b4 2020-01-13 stsp Show the status of each affected file, using the following status codes:
498 bb51a5b4 2020-01-13 stsp .Bl -column YXZ description
499 bb51a5b4 2020-01-13 stsp .It A Ta new file was added
500 bb51a5b4 2020-01-13 stsp .It E Ta file already exists in work tree's meta-data
504 5d7c1dab 2018-04-01 stsp .Ar work tree path
505 c844a238 2019-02-06 stsp is not specified, either use the last component of
506 5d7c1dab 2018-04-01 stsp .Ar repository path ,
508 5d7c1dab 2018-04-01 stsp .Ar path prefix
509 c844a238 2019-02-06 stsp was specified use the last component of
510 5d7c1dab 2018-04-01 stsp .Ar path prefix .
512 38e11793 2018-06-13 stsp The options for
513 38e11793 2018-06-13 stsp .Cm got checkout
514 38e11793 2018-06-13 stsp are as follows:
515 38e11793 2018-06-13 stsp .Bl -tag -width Ds
517 bb51a5b4 2020-01-13 stsp Proceed with the checkout operation even if the directory at
518 bb51a5b4 2020-01-13 stsp .Ar work-tree-path
519 bb51a5b4 2020-01-13 stsp is not empty.
520 bb51a5b4 2020-01-13 stsp Existing files will be left intact.
521 08573d5b 2019-05-14 stsp .It Fl b Ar branch
522 3c575567 2019-07-28 stsp Check out files from a commit on the specified
523 08573d5b 2019-05-14 stsp .Ar branch .
524 08573d5b 2019-05-14 stsp If this option is not specified, a branch resolved via the repository's HEAD
525 08573d5b 2019-05-14 stsp reference will be used.
526 8069f636 2019-01-12 stsp .It Fl c Ar commit
527 8069f636 2019-01-12 stsp Check out files from the specified
529 3c575567 2019-07-28 stsp on the selected branch.
530 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
531 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
532 0e1b0230 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
533 0e1b0230 2019-07-07 stsp automatically, provided the abbreviation is unique.
534 08573d5b 2019-05-14 stsp If this option is not specified, the most recent commit on the selected
535 08573d5b 2019-05-14 stsp branch will be used.
537 4b6c9460 2020-03-05 stsp If the specified
539 4b6c9460 2020-03-05 stsp is not contained in the selected branch, a different branch which contains
540 4b6c9460 2020-03-05 stsp this commit must be specified with the
543 4b06140e 2022-03-22 thomas If no such branch is known, a new branch must be created for this
544 4b6c9460 2020-03-05 stsp commit with
545 4b6c9460 2020-03-05 stsp .Cm got branch
547 4b6c9460 2020-03-05 stsp .Cm got checkout
548 4b6c9460 2020-03-05 stsp can be used.
549 4b6c9460 2020-03-05 stsp Checking out work trees with an unknown branch is intentionally not supported.
550 38e11793 2018-06-13 stsp .It Fl p Ar path-prefix
551 38e11793 2018-06-13 stsp Restrict the work tree to a subset of the repository's tree hierarchy.
552 38e11793 2018-06-13 stsp Only files beneath the specified
553 38e11793 2018-06-13 stsp .Ar path-prefix
554 38e11793 2018-06-13 stsp will be checked out.
556 4ad4a1ec 2021-09-13 tracey Silence progress output.
559 4ad4a1ec 2021-09-13 tracey .It Cm update Oo Fl b Ar branch Oc Oo Fl c Ar commit Oc Oo Fl q Oc Op Ar path ...
560 d912d125 2021-11-04 thomas .Dl Pq alias: Cm up
561 4f331d3a 2020-04-01 stsp Update an existing work tree to a different
562 4f331d3a 2020-04-01 stsp .Ar commit .
563 4f331d3a 2020-04-01 stsp Change existing files in the work tree as necessary to match file contents
564 4f331d3a 2020-04-01 stsp of this commit.
565 4f331d3a 2020-04-01 stsp Preserve any local changes in the work tree and merge them with the
566 4f331d3a 2020-04-01 stsp incoming changes.
568 5036ab18 2020-04-18 stsp Files which already contain merge conflicts will not be updated to avoid
569 5036ab18 2020-04-18 stsp further complications.
570 5036ab18 2020-04-18 stsp Such files will be updated when
571 5036ab18 2020-04-18 stsp .Cm got update
572 5036ab18 2020-04-18 stsp is run again after merge conflicts have been resolved.
573 4b06140e 2022-03-22 thomas If the conflicting changes are no longer needed, affected files can be
574 5036ab18 2020-04-18 stsp reverted with
575 5036ab18 2020-04-18 stsp .Cm got revert
576 5036ab18 2020-04-18 stsp before running
577 5036ab18 2020-04-18 stsp .Cm got update
580 7f838b36 2019-02-08 stsp Show the status of each affected file, using the following status codes:
581 7f838b36 2019-02-08 stsp .Bl -column YXZ description
582 7f838b36 2019-02-08 stsp .It U Ta file was updated and contained no local changes
583 7f838b36 2019-02-08 stsp .It G Ta file was updated and local changes were merged cleanly
584 7f838b36 2019-02-08 stsp .It C Ta file was updated and conflicts occurred during merge
585 7f838b36 2019-02-08 stsp .It D Ta file was deleted
586 7f838b36 2019-02-08 stsp .It A Ta new file was added
587 1dd86744 2019-08-12 anthony .It \(a~ Ta versioned file is obstructed by a non-regular file
588 a378724f 2019-02-10 stsp .It ! Ta a missing versioned file was restored
589 5036ab18 2020-04-18 stsp .It # Ta file was not updated because it contains merge conflicts
590 3b9f0f87 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
595 f2ea84fa 2019-07-27 stsp is specified, update the entire work tree.
596 f2ea84fa 2019-07-27 stsp Otherwise, restrict the update operation to files at or within the
597 f2ea84fa 2019-07-27 stsp specified paths.
598 f2ea84fa 2019-07-27 stsp Each path is required to exist in the update operation's target commit.
599 f2ea84fa 2019-07-27 stsp Files in the work tree outside specified paths will remain unchanged and
600 f2ea84fa 2019-07-27 stsp will retain their previously recorded base commit.
603 f2cf8fbb 2019-04-04 stsp commands may refuse to run while the work tree contains files from
604 c4cdcb68 2019-04-03 stsp multiple base commits.
605 f2cf8fbb 2019-04-04 stsp The base commit of such a work tree can be made consistent by running
606 47ec7be7 2019-05-12 stsp .Cm got update
607 47ec7be7 2019-05-12 stsp across the entire work tree.
608 024e9686 2019-05-14 stsp Specifying a
610 024e9686 2019-05-14 stsp is incompatible with the
614 4ed9f614 2019-08-04 stsp .Cm got update
615 4ed9f614 2019-08-04 stsp cannot update paths with staged changes.
616 4ed9f614 2019-08-04 stsp If changes have been staged with
617 4ed9f614 2019-08-04 stsp .Cm got stage ,
618 bc3056e3 2019-08-18 stsp these changes must first be committed with
619 4ed9f614 2019-08-04 stsp .Cm got commit
620 4ed9f614 2019-08-04 stsp or unstaged with
621 4ed9f614 2019-08-04 stsp .Cm got unstage .
623 507dc3bb 2018-12-29 stsp The options for
624 507dc3bb 2018-12-29 stsp .Cm got update
625 507dc3bb 2018-12-29 stsp are as follows:
626 507dc3bb 2018-12-29 stsp .Bl -tag -width Ds
627 024e9686 2019-05-14 stsp .It Fl b Ar branch
628 024e9686 2019-05-14 stsp Switch the work tree's branch reference to the specified
630 024e9686 2019-05-14 stsp before updating the work tree.
631 024e9686 2019-05-14 stsp This option requires that all paths in the work tree are updated.
633 4f331d3a 2020-04-01 stsp As usual, any local changes in the work tree will be preserved.
634 4f331d3a 2020-04-01 stsp This can be useful when switching to a newly created branch in order
635 4f331d3a 2020-04-01 stsp to commit existing local changes to this branch.
637 4f331d3a 2020-04-01 stsp Any local changes must be dealt with separately in order to obtain a
638 4f331d3a 2020-04-01 stsp work tree with pristine file contents corresponding exactly to the specified
639 4f331d3a 2020-04-01 stsp .Ar branch .
640 4f331d3a 2020-04-01 stsp Such changes could first be committed to a different branch with
641 4f331d3a 2020-04-01 stsp .Cm got commit ,
642 4f331d3a 2020-04-01 stsp or could be discarded with
643 4f331d3a 2020-04-01 stsp .Cm got revert .
644 507dc3bb 2018-12-29 stsp .It Fl c Ar commit
645 507dc3bb 2018-12-29 stsp Update the work tree to the specified
646 507dc3bb 2018-12-29 stsp .Ar commit .
647 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
648 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
649 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
650 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
651 024e9686 2019-05-14 stsp If this option is not specified, the most recent commit on the work tree's
652 024e9686 2019-05-14 stsp branch will be used.
654 4ad4a1ec 2021-09-13 tracey Silence progress output.
657 ac372b60 2021-09-15 stsp .It Cm status Oo Fl I Oc Oo Fl s Ar status-codes Oc Oo Fl S Ar status-codes Oc Op Ar path ...
658 d912d125 2021-11-04 thomas .Dl Pq alias: Cm st
659 6cd959e6 2019-03-26 stsp Show the current modification status of files in a work tree,
660 6bad629b 2019-02-04 stsp using the following status codes:
661 6bad629b 2019-02-04 stsp .Bl -column YXZ description
662 6bad629b 2019-02-04 stsp .It M Ta modified file
663 079890a9 2019-03-26 stsp .It A Ta file scheduled for addition in next commit
664 079890a9 2019-03-26 stsp .It D Ta file scheduled for deletion in next commit
665 7154f6ce 2019-03-27 stsp .It C Ta modified or added file which contains merge conflicts
666 6bad629b 2019-02-04 stsp .It ! Ta versioned file was expected on disk but is missing
667 1dd86744 2019-08-12 anthony .It \(a~ Ta versioned file is obstructed by a non-regular file
668 6bad629b 2019-02-04 stsp .It ? Ta unversioned item not tracked by
670 1ebedb77 2019-10-19 stsp .It m Ta modified file modes (executable bit only)
671 2a06fe5f 2019-08-24 stsp .It N Ta non-existent
673 2a06fe5f 2019-08-24 stsp specified on the command line
678 72ea6654 2019-07-27 stsp is specified, show modifications in the entire work tree.
679 72ea6654 2019-07-27 stsp Otherwise, show modifications at or within the specified paths.
681 4ed9f614 2019-08-04 stsp If changes have been staged with
682 4ed9f614 2019-08-04 stsp .Cm got stage ,
683 4ed9f614 2019-08-04 stsp staged changes are shown in the second output column, using the following
684 4ed9f614 2019-08-04 stsp status codes:
685 4ed9f614 2019-08-04 stsp .Bl -column YXZ description
686 4ed9f614 2019-08-04 stsp .It M Ta file modification is staged
687 4ed9f614 2019-08-04 stsp .It A Ta file addition is staged
688 4ed9f614 2019-08-04 stsp .It D Ta file deletion is staged
691 95ac67f0 2019-08-08 stsp Changes created on top of staged changes are indicated in the first column:
692 4ed9f614 2019-08-04 stsp .Bl -column YXZ description
693 95ac67f0 2019-08-08 stsp .It MM Ta file was modified after earlier changes have been staged
694 95ac67f0 2019-08-08 stsp .It MA Ta file was modified after having been staged for addition
697 081470ac 2020-08-13 stsp The options for
698 081470ac 2020-08-13 stsp .Cm got status
699 081470ac 2020-08-13 stsp are as follows:
700 081470ac 2020-08-13 stsp .Bl -tag -width Ds
702 f6343036 2021-06-22 stsp Show unversioned files even if they match an ignore pattern.
703 081470ac 2020-08-13 stsp .It Fl s Ar status-codes
704 081470ac 2020-08-13 stsp Only show files with a modification status matching any of the
705 00357e4d 2021-09-14 tracey single-character status codes contained in the
706 00357e4d 2021-09-14 tracey .Ar status-codes
707 00357e4d 2021-09-14 tracey argument.
708 00357e4d 2021-09-14 tracey Any combination of codes from the above list of possible status codes
709 00357e4d 2021-09-14 tracey may be specified.
710 00357e4d 2021-09-14 tracey For staged files, status codes displayed in either column will be matched.
711 b043307b 2021-09-14 stsp Cannot be used together with the
714 00357e4d 2021-09-14 tracey .It Fl S Ar status-codes
715 00357e4d 2021-09-14 tracey Suppress the output of files with a modification status matching any of the
716 081470ac 2020-08-13 stsp single-character status codes contained in the
717 081470ac 2020-08-13 stsp .Ar status-codes
719 081470ac 2020-08-13 stsp Any combination of codes from the above list of possible status codes
720 081470ac 2020-08-13 stsp may be specified.
721 081470ac 2020-08-13 stsp For staged files, status codes displayed in either column will be matched.
722 b043307b 2021-09-14 stsp Cannot be used together with the
727 6841da00 2019-08-08 stsp For compatibility with
730 bd8de430 2019-10-04 stsp .Xr git 1 ,
731 6841da00 2019-08-08 stsp .Cm got status
734 bd8de430 2019-10-04 stsp patterns from
735 6841da00 2019-08-08 stsp .Pa .cvsignore
737 bd8de430 2019-10-04 stsp .Pa .gitignore
738 6841da00 2019-08-08 stsp files in each traversed directory and will not display unversioned files
739 bd8de430 2019-10-04 stsp which match these patterns.
740 bd8de430 2019-10-04 stsp As an extension to
742 bd8de430 2019-10-04 stsp matching rules,
743 bd8de430 2019-10-04 stsp .Cm got status
744 bd8de430 2019-10-04 stsp supports consecutive asterisks,
746 bd8de430 2019-10-04 stsp which will match an arbitrary amount of directories.
748 6841da00 2019-08-08 stsp .Xr cvs 1 ,
749 6841da00 2019-08-08 stsp .Cm got status
750 6841da00 2019-08-08 stsp only supports a single ignore pattern per line.
752 bd8de430 2019-10-04 stsp .Xr git 1 ,
753 bd8de430 2019-10-04 stsp .Cm got status
754 bd8de430 2019-10-04 stsp does not support negated ignore patterns prefixed with
756 bd8de430 2019-10-04 stsp and gives no special significance to the location of path component separators,
758 bd8de430 2019-10-04 stsp in a pattern.
759 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
760 38e11793 2018-06-13 stsp Display history of a repository.
763 04ca23f4 2018-07-16 stsp is specified, show only commits which modified this path.
764 dc990cbf 2020-02-22 stsp If invoked in a work tree, the
766 dc990cbf 2020-02-22 stsp is interpreted relative to the current working directory,
767 dc990cbf 2020-02-22 stsp and the work tree's path prefix is implicitly prepended.
768 dc990cbf 2020-02-22 stsp Otherwise, the path is interpreted relative to the repository root.
770 38e11793 2018-06-13 stsp The options for
771 38e11793 2018-06-13 stsp .Cm got log
772 38e11793 2018-06-13 stsp are as follows:
773 38e11793 2018-06-13 stsp .Bl -tag -width Ds
775 1137e0ae 2020-01-27 stsp Display individual commits which were merged into the current branch
776 1137e0ae 2020-01-27 stsp from other branches.
777 48c8c60d 2020-01-27 stsp By default,
778 48c8c60d 2020-01-27 stsp .Cm got log
779 48c8c60d 2020-01-27 stsp shows the linear history of the current branch only.
780 38e11793 2018-06-13 stsp .It Fl c Ar commit
781 38e11793 2018-06-13 stsp Start traversing history at the specified
782 38e11793 2018-06-13 stsp .Ar commit .
783 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
784 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
785 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
786 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
787 1cc14b9f 2019-05-14 stsp If this option is not specified, default to the work tree's current branch
788 1cc14b9f 2019-05-14 stsp if invoked in a work tree, or to the repository's HEAD reference.
789 c0cc5c62 2018-10-18 stsp .It Fl C Ar number
790 c0cc5c62 2018-10-18 stsp Set the number of context lines shown in diffs with
792 c0cc5c62 2018-10-18 stsp By default, 3 lines of context are shown.
793 6238ee32 2018-06-13 stsp .It Fl l Ar N
794 6238ee32 2018-06-13 stsp Limit history traversal to a given number of commits.
795 b1ebc001 2019-08-13 stsp If this option is not specified, a default limit value of zero is used,
796 b1ebc001 2019-08-13 stsp which is treated as an unbounded limit.
798 b1ebc001 2019-08-13 stsp .Ev GOT_LOG_DEFAULT_LIMIT
799 b1ebc001 2019-08-13 stsp environment variable may be set to change this default value.
801 6238ee32 2018-06-13 stsp Display the patch of modifications made in each commit.
804 44392932 2019-08-25 stsp is specified, only show the patch of modifications at or within this path.
806 0208f208 2020-05-05 stsp Display the list of file paths changed in each commit, using the following
807 0208f208 2020-05-05 stsp status codes:
808 0208f208 2020-05-05 stsp .Bl -column YXZ description
809 0208f208 2020-05-05 stsp .It M Ta modified file
810 0208f208 2020-05-05 stsp .It D Ta file was deleted
811 0208f208 2020-05-05 stsp .It A Ta new file was added
812 0208f208 2020-05-05 stsp .It m Ta modified file modes (executable bit only)
814 c6390436 2019-11-29 kn .It Fl s Ar search-pattern
815 c6390436 2019-11-29 kn If specified, show only commits with a log message matched by the extended
816 6841bf13 2019-11-29 kn regular expression
817 6841bf13 2019-11-29 kn .Ar search-pattern .
818 0208f208 2020-05-05 stsp When used together with
820 0208f208 2020-05-05 stsp then the file paths changed by a commit can be matched as well.
821 6841bf13 2019-11-29 kn Regular expression syntax is documented in
822 6841bf13 2019-11-29 kn .Xr re_format 7 .
823 04ca23f4 2018-07-16 stsp .It Fl r Ar repository-path
824 04ca23f4 2018-07-16 stsp Use the repository at the specified path.
825 04ca23f4 2018-07-16 stsp If not specified, assume the repository is located at or above the current
826 04ca23f4 2018-07-16 stsp working directory.
827 e9cf2e30 2019-02-05 stsp If this directory is a
829 e9cf2e30 2019-02-05 stsp work tree, use the repository path associated with this work tree.
831 dbec59df 2020-04-18 stsp Determine a set of commits to display as usual, but display these commits
832 dbec59df 2020-04-18 stsp in reverse order.
833 d1fe46f9 2020-04-18 stsp .It Fl x Ar commit
834 4e20a648 2021-03-21 jrick Stop traversing commit history immediately after the specified
836 52ab7958 2020-04-18 stsp has been traversed.
837 d1fe46f9 2020-04-18 stsp This option has no effect if the specified
839 d1fe46f9 2020-04-18 stsp is never traversed.
842 cc8021af 2021-10-12 thomas .It Cm diff Oo Fl a Oc Oo Fl c Ar commit Oc Oo Fl C Ar number Oc Oo Fl r Ar repository-path Oc Oo Fl s Oc Oo Fl P Oc Oo Fl w Oc Op Ar object1 Ar object2 | Ar path ...
843 d912d125 2021-11-04 thomas .Dl Pq alias: Cm di
844 30f6c0c6 2021-10-08 thomas When invoked within a work tree without any arguments, display all
845 bd81cfb7 2020-04-19 stsp local changes in the work tree.
846 30f6c0c6 2021-10-08 thomas If one or more
848 30f6c0c6 2021-10-08 thomas arguments are specified, only show changes within the specified paths.
850 d24820bf 2019-08-11 stsp If two arguments are provided, treat each argument as a reference, a tag
851 d24820bf 2019-08-11 stsp name, or an object ID SHA1 hash, and display differences between the
852 d24820bf 2019-08-11 stsp corresponding objects.
853 3f8b7d6a 2018-04-01 stsp Both objects must be of the same type (blobs, trees, or commits).
854 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
855 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
856 30f6c0c6 2021-10-08 thomas If none of these interpretations produce a valid result or if the
858 30f6c0c6 2021-10-08 thomas option is used,
860 30f6c0c6 2021-10-08 thomas .Cm got diff
861 30f6c0c6 2021-10-08 thomas is running in a work tree, attempt to interpret the two arguments as paths.
863 c0cc5c62 2018-10-18 stsp The options for
864 c0cc5c62 2018-10-18 stsp .Cm got diff
865 c0cc5c62 2018-10-18 stsp are as follows:
866 c0cc5c62 2018-10-18 stsp .Bl -tag -width Ds
868 64453f7e 2020-11-21 stsp Treat file contents as ASCII text even if binary data is detected.
869 cc8021af 2021-10-12 thomas .It Fl c Ar commit
870 cc8021af 2021-10-12 thomas Show differences between commits in the repository.
871 cc8021af 2021-10-12 thomas This options may be used up to two times.
872 cc8021af 2021-10-12 thomas When used only once, show differences between the specified
873 cc8021af 2021-10-12 thomas .Ar commit
874 cc8021af 2021-10-12 thomas and its first parent commit.
875 cc8021af 2021-10-12 thomas When used twice, show differences between the two specified commits.
877 cc8021af 2021-10-12 thomas The expected argument is a commit ID SHA1 hash or an existing reference
878 cc8021af 2021-10-12 thomas or tag name which will be resolved to a commit ID.
879 cc8021af 2021-10-12 thomas An abbreviated hash argument will be expanded to a full SHA1 hash
880 cc8021af 2021-10-12 thomas automatically, provided the abbreviation is unique.
884 cc8021af 2021-10-12 thomas option is used, all non-option arguments will be interpreted as paths.
885 cc8021af 2021-10-12 thomas If one or more such
887 cc8021af 2021-10-12 thomas arguments are provided, only show differences for the specified paths.
889 cc8021af 2021-10-12 thomas Cannot be used together with the
892 c0cc5c62 2018-10-18 stsp .It Fl C Ar number
893 c0cc5c62 2018-10-18 stsp Set the number of context lines shown in the diff.
894 c0cc5c62 2018-10-18 stsp By default, 3 lines of context are shown.
895 b72f483a 2019-02-05 stsp .It Fl r Ar repository-path
896 b72f483a 2019-02-05 stsp Use the repository at the specified path.
897 b72f483a 2019-02-05 stsp If not specified, assume the repository is located at or above the current
898 b72f483a 2019-02-05 stsp working directory.
899 b72f483a 2019-02-05 stsp If this directory is a
901 b72f483a 2019-02-05 stsp work tree, use the repository path associated with this work tree.
903 4ed9f614 2019-08-04 stsp Show changes staged with
904 4ed9f614 2019-08-04 stsp .Cm got stage
905 bd81cfb7 2020-04-19 stsp instead of showing local changes in the work tree.
906 30f6c0c6 2021-10-08 thomas This option is only valid when
907 30f6c0c6 2021-10-08 thomas .Cm got diff
908 30f6c0c6 2021-10-08 thomas is invoked in a work tree.
910 30f6c0c6 2021-10-08 thomas Interpret all arguments as paths only.
911 30f6c0c6 2021-10-08 thomas This option can be used to resolve ambiguity in cases where paths
912 30f6c0c6 2021-10-08 thomas look like tag names, reference names, or object IDs.
913 4ed9f614 2019-08-04 stsp This option is only valid when
914 4ed9f614 2019-08-04 stsp .Cm got diff
915 4ed9f614 2019-08-04 stsp is invoked in a work tree.
917 63035f9f 2019-10-06 stsp Ignore whitespace-only changes.
920 dfc23429 2019-08-11 stsp .It Cm blame Oo Fl c Ar commit Oc Oo Fl r Ar repository-path Oc Ar path
921 d912d125 2021-11-04 thomas .Dl Pq alias: Cm bl
922 1ff8e573 2018-08-02 stsp Display line-by-line history of a file at the specified path.
924 1ff8e573 2018-08-02 stsp The options for
925 1ff8e573 2018-08-02 stsp .Cm got blame
926 1ff8e573 2018-08-02 stsp are as follows:
927 1ff8e573 2018-08-02 stsp .Bl -tag -width Ds
928 1ff8e573 2018-08-02 stsp .It Fl c Ar commit
929 1ff8e573 2018-08-02 stsp Start traversing history at the specified
930 1ff8e573 2018-08-02 stsp .Ar commit .
931 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
932 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
933 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
934 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
935 1ff8e573 2018-08-02 stsp .It Fl r Ar repository-path
936 1ff8e573 2018-08-02 stsp Use the repository at the specified path.
937 1ff8e573 2018-08-02 stsp If not specified, assume the repository is located at or above the current
938 1ff8e573 2018-08-02 stsp working directory.
939 0c06baac 2019-02-05 stsp If this directory is a
941 0c06baac 2019-02-05 stsp work tree, use the repository path associated with this work tree.
944 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
945 d912d125 2021-11-04 thomas .Dl Pq alias: Cm tr
946 5de5890b 2018-10-18 stsp Display a listing of files and directories at the specified
947 5de5890b 2018-10-18 stsp directory path in the repository.
948 db0c2996 2019-02-10 stsp Entries shown in this listing may carry one of the following trailing
949 db0c2996 2019-02-10 stsp annotations:
950 db0c2996 2019-02-10 stsp .Bl -column YXZ description
951 848d6979 2019-08-12 stsp .It @ Ta entry is a symbolic link
952 db0c2996 2019-02-10 stsp .It / Ta entry is a directory
953 db0c2996 2019-02-10 stsp .It * Ta entry is an executable file
954 63c5ca5d 2019-08-24 stsp .It $ Ta entry is a Git submodule
957 0d6c6ee3 2020-05-20 stsp Symbolic link entries are also annotated with the target path of the link.
961 0c849583 2019-02-05 stsp is specified, list the repository path corresponding to the current
962 0c849583 2019-02-05 stsp directory of the work tree, or the root directory of the repository
963 0c849583 2019-02-05 stsp if there is no work tree.
965 5de5890b 2018-10-18 stsp The options for
966 5de5890b 2018-10-18 stsp .Cm got tree
967 5de5890b 2018-10-18 stsp are as follows:
968 5de5890b 2018-10-18 stsp .Bl -tag -width Ds
969 5de5890b 2018-10-18 stsp .It Fl c Ar commit
970 5de5890b 2018-10-18 stsp List files and directories as they appear in the specified
971 5de5890b 2018-10-18 stsp .Ar commit .
972 30837e32 2019-07-25 stsp The expected argument is a commit ID SHA1 hash or an existing reference
973 303e2782 2019-08-09 stsp or tag name which will be resolved to a commit ID.
974 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
975 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
976 5de5890b 2018-10-18 stsp .It Fl r Ar repository-path
977 5de5890b 2018-10-18 stsp Use the repository at the specified path.
978 5de5890b 2018-10-18 stsp If not specified, assume the repository is located at or above the current
979 5de5890b 2018-10-18 stsp working directory.
980 0c849583 2019-02-05 stsp If this directory is a
982 0c849583 2019-02-05 stsp work tree, use the repository path associated with this work tree.
984 5de5890b 2018-10-18 stsp Show object IDs of files (blob objects) and directories (tree objects).
986 0c849583 2019-02-05 stsp Recurse into sub-directories in the repository.
988 2bf0fa54 2021-11-20 thomas .It Cm ref Oo Fl r Ar repository-path Oc Oo Fl l Oc Oo Fl t Oc Oo Fl c Ar object Oc Oo Fl s Ar reference Oc Oo Fl d Oc Op Ar name
989 d0eebce4 2019-03-11 stsp Manage references in a repository.
991 e31abbf2 2020-03-22 stsp References may be listed, created, deleted, and changed.
992 e31abbf2 2020-03-22 stsp When creating, deleting, or changing a reference the specified
994 e31abbf2 2020-03-22 stsp must be an absolute reference name, i.e. it must begin with
995 f16e4044 2019-10-09 stsp .Dq refs/ .
997 d0eebce4 2019-03-11 stsp The options for
998 d0eebce4 2019-03-11 stsp .Cm got ref
999 d0eebce4 2019-03-11 stsp are as follows:
1000 d0eebce4 2019-03-11 stsp .Bl -tag -width Ds
1001 d0eebce4 2019-03-11 stsp .It Fl r Ar repository-path
1002 d0eebce4 2019-03-11 stsp Use the repository at the specified path.
1003 d0eebce4 2019-03-11 stsp If not specified, assume the repository is located at or above the current
1004 d0eebce4 2019-03-11 stsp working directory.
1005 d0eebce4 2019-03-11 stsp If this directory is a
1007 d0eebce4 2019-03-11 stsp work tree, use the repository path associated with this work tree.
1009 b2070a3f 2020-03-22 stsp List references in the repository.
1012 b2070a3f 2020-03-22 stsp is specified, list all existing references in the repository.
1015 b2070a3f 2020-03-22 stsp is a reference namespace, list all references in this namespace.
1016 b2070a3f 2020-03-22 stsp Otherwise, show only the reference with the given
1017 b2070a3f 2020-03-22 stsp .Ar name .
1018 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
1022 2bf0fa54 2021-11-20 thomas .It Fl t
1023 2bf0fa54 2021-11-20 thomas Sort listed references by modification time (most recently modified first)
1024 2bf0fa54 2021-11-20 thomas instead of sorting by lexicographical order.
1025 2bf0fa54 2021-11-20 thomas Use of this option requires the
1027 2bf0fa54 2021-11-20 thomas option to be used as well.
1028 e31abbf2 2020-03-22 stsp .It Fl c Ar object
1029 e31abbf2 2020-03-22 stsp Create a reference or change an existing reference.
1030 e31abbf2 2020-03-22 stsp The reference with the specified
1032 e31abbf2 2020-03-22 stsp will point at the specified
1033 1795b260 2021-04-02 kn .Ar object .
1034 e31abbf2 2020-03-22 stsp The expected
1035 e31abbf2 2020-03-22 stsp .Ar object
1036 e31abbf2 2020-03-22 stsp argument is a ID SHA1 hash or an existing reference or tag name which will
1037 e31abbf2 2020-03-22 stsp be resolved to the ID of a corresponding commit, tree, tag, or blob object.
1038 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
1040 e31abbf2 2020-03-22 stsp .It Fl s Ar reference
1041 e31abbf2 2020-03-22 stsp Create a symbolic reference, or change an existing symbolic reference.
1042 e31abbf2 2020-03-22 stsp The symbolic reference with the specified
1044 e31abbf2 2020-03-22 stsp will point at the specified
1045 e31abbf2 2020-03-22 stsp .Ar reference
1046 e31abbf2 2020-03-22 stsp which must already exist in the repository.
1047 d1c1ae5f 2019-08-12 stsp Care should be taken not to create loops between references when
1048 d1c1ae5f 2019-08-12 stsp this option is used.
1049 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
1052 e31abbf2 2020-03-22 stsp Delete the reference with the specified
1054 e31abbf2 2020-03-22 stsp from the repository.
1055 601aba22 2021-03-21 stsp Any commit, tree, tag, and blob objects belonging to deleted references
1056 601aba22 2021-03-21 stsp remain in the repository and may be removed separately with
1057 e6786710 2021-07-03 stsp Git's garbage collector or
1058 e6786710 2021-07-03 stsp .Cm gotadmin cleanup .
1059 e31abbf2 2020-03-22 stsp Cannot be used together with any other options except
1063 053ccfc1 2022-01-12 thomas .It Cm branch Oo Fl c Ar commit Oc Oo Fl r Ar repository-path Oc Oo Fl l Oc Oo Fl t Oc Oo Fl d Ar name Oc Oo Fl n Oc Op Ar name
1064 d912d125 2021-11-04 thomas .Dl Pq alias: Cm br
1065 da76fce2 2020-02-24 stsp Create, list, or delete branches.
1067 34d4e04c 2021-02-08 stsp Local branches are managed via references which live in the
1068 4e759de4 2019-06-26 stsp .Dq refs/heads/
1069 4e759de4 2019-06-26 stsp reference namespace.
1071 4e759de4 2019-06-26 stsp .Cm got branch
1072 2f1457c6 2021-08-27 stsp command creates references in this namespace only.
1074 4b06140e 2022-03-22 thomas When deleting branches, the specified
1076 2f1457c6 2021-08-27 stsp is searched in the
1077 2f1457c6 2021-08-27 stsp .Dq refs/heads
1078 2f1457c6 2021-08-27 stsp reference namespace first.
1079 4b06140e 2022-03-22 thomas If no corresponding branch is found, the
1080 2f1457c6 2021-08-27 stsp .Dq refs/remotes
1081 2f1457c6 2021-08-27 stsp namespace will be searched next.
1083 ad89fa31 2019-10-04 stsp If invoked in a work tree without any arguments, print the name of the
1084 ad89fa31 2019-10-04 stsp work tree's current branch.
1088 a74f7e83 2019-11-10 stsp argument is passed, attempt to create a branch reference with the given name.
1089 a74f7e83 2019-11-10 stsp By default the new branch reference will point at the latest commit on the
1090 a74f7e83 2019-11-10 stsp work tree's current branch if invoked in a work tree, and otherwise to a commit
1091 a74f7e83 2019-11-10 stsp resolved via the repository's HEAD reference.
1093 da76fce2 2020-02-24 stsp If invoked in a work tree, once the branch was created successfully
1094 da76fce2 2020-02-24 stsp switch the work tree's head reference to the newly created branch and
1095 da76fce2 2020-02-24 stsp update files across the entire work tree, just like
1096 da76fce2 2020-02-24 stsp .Cm got update -b Ar name
1098 da76fce2 2020-02-24 stsp Show the status of each affected file, using the following status codes:
1099 da76fce2 2020-02-24 stsp .Bl -column YXZ description
1100 da76fce2 2020-02-24 stsp .It U Ta file was updated and contained no local changes
1101 da76fce2 2020-02-24 stsp .It G Ta file was updated and local changes were merged cleanly
1102 da76fce2 2020-02-24 stsp .It C Ta file was updated and conflicts occurred during merge
1103 da76fce2 2020-02-24 stsp .It D Ta file was deleted
1104 da76fce2 2020-02-24 stsp .It A Ta new file was added
1105 da76fce2 2020-02-24 stsp .It \(a~ Ta versioned file is obstructed by a non-regular file
1106 da76fce2 2020-02-24 stsp .It ! Ta a missing versioned file was restored
1109 4e759de4 2019-06-26 stsp The options for
1110 4e759de4 2019-06-26 stsp .Cm got branch
1111 4e759de4 2019-06-26 stsp are as follows:
1112 4e759de4 2019-06-26 stsp .Bl -tag -width Ds
1113 a74f7e83 2019-11-10 stsp .It Fl c Ar commit
1114 a74f7e83 2019-11-10 stsp Make a newly created branch reference point at the specified
1115 a74f7e83 2019-11-10 stsp .Ar commit .
1116 a74f7e83 2019-11-10 stsp The expected
1117 a74f7e83 2019-11-10 stsp .Ar commit
1118 a74f7e83 2019-11-10 stsp argument is a commit ID SHA1 hash or an existing reference
1119 a74f7e83 2019-11-10 stsp or tag name which will be resolved to a commit ID.
1120 4e759de4 2019-06-26 stsp .It Fl r Ar repository-path
1121 4e759de4 2019-06-26 stsp Use the repository at the specified path.
1122 4e759de4 2019-06-26 stsp If not specified, assume the repository is located at or above the current
1123 4e759de4 2019-06-26 stsp working directory.
1124 4e759de4 2019-06-26 stsp If this directory is a
1126 4e759de4 2019-06-26 stsp work tree, use the repository path associated with this work tree.
1128 34d4e04c 2021-02-08 stsp List all existing branches in the repository, including copies of remote
1129 34d4e04c 2021-02-08 stsp repositories' branches in the
1130 34d4e04c 2021-02-08 stsp .Dq refs/remotes/
1131 34d4e04c 2021-02-08 stsp reference namespace.
1133 ba882ee3 2019-07-11 stsp If invoked in a work tree, the work tree's current branch is shown
1134 ba882ee3 2019-07-11 stsp with one the following annotations:
1135 ba882ee3 2019-07-11 stsp .Bl -column YXZ description
1136 ba882ee3 2019-07-11 stsp .It * Ta work tree's base commit matches the branch tip
1137 1dd86744 2019-08-12 anthony .It \(a~ Ta work tree's base commit is out-of-date
1139 a0b48eaf 2021-11-20 thomas .It Fl t
1140 a0b48eaf 2021-11-20 thomas Sort listed branches by modification time (most recently modified first)
1141 a0b48eaf 2021-11-20 thomas instead of sorting by lexicographical order.
1142 a0b48eaf 2021-11-20 thomas Branches in the
1143 a0b48eaf 2021-11-20 thomas .Dq refs/heads/
1144 a0b48eaf 2021-11-20 thomas reference namespace are listed before branches in
1145 a0b48eaf 2021-11-20 thomas .Dq refs/remotes/
1146 a0b48eaf 2021-11-20 thomas regardless.
1147 a0b48eaf 2021-11-20 thomas Use of this option requires the
1149 a0b48eaf 2021-11-20 thomas option to be used as well.
1150 4e759de4 2019-06-26 stsp .It Fl d Ar name
1151 2f1457c6 2021-08-27 stsp Delete the branch with the specified
1154 2f1457c6 2021-08-27 stsp .Dq refs/heads
1156 2f1457c6 2021-08-27 stsp .Dq refs/remotes
1157 2f1457c6 2021-08-27 stsp reference namespace.
1159 7acfb25b 2019-07-11 stsp Only the branch reference is deleted.
1160 7acfb25b 2019-07-11 stsp Any commit, tree, and blob objects belonging to the branch
1161 74d012d1 2019-07-11 stsp remain in the repository and may be removed separately with
1162 e6786710 2021-07-03 stsp Git's garbage collector or
1163 e6786710 2021-07-03 stsp .Cm gotadmin cleanup .
1165 da76fce2 2020-02-24 stsp Do not switch and update the work tree after creating a new branch.
1167 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
1168 8e7bd50a 2019-08-22 stsp Manage tags in a repository.
1170 8e7bd50a 2019-08-22 stsp Tags are managed via references which live in the
1171 8e7bd50a 2019-08-22 stsp .Dq refs/tags/
1172 8e7bd50a 2019-08-22 stsp reference namespace.
1174 8e7bd50a 2019-08-22 stsp .Cm got tag
1175 8e7bd50a 2019-08-22 stsp command operates on references in this namespace only.
1176 b3cd068e 2019-08-22 stsp References in this namespace point at tag objects which contain a pointer
1177 b3cd068e 2019-08-22 stsp to another object, a tag message, as well as author and timestamp information.
1179 80106605 2020-02-24 stsp Attempt to create a tag with the given
1180 8e7bd50a 2019-08-22 stsp .Ar name ,
1181 8e7bd50a 2019-08-22 stsp and make this tag point at the given
1182 8e7bd50a 2019-08-22 stsp .Ar commit .
1183 8e7bd50a 2019-08-22 stsp If no commit is specified, default to the latest commit on the work tree's
1184 8e7bd50a 2019-08-22 stsp current branch if invoked in a work tree, and to a commit resolved via
1185 8e7bd50a 2019-08-22 stsp the repository's HEAD reference otherwise.
1187 8e7bd50a 2019-08-22 stsp The options for
1188 8e7bd50a 2019-08-22 stsp .Cm got tag
1189 8e7bd50a 2019-08-22 stsp are as follows:
1190 8e7bd50a 2019-08-22 stsp .Bl -tag -width Ds
1191 80106605 2020-02-24 stsp .It Fl c Ar commit
1192 80106605 2020-02-24 stsp Make the newly created tag reference point at the specified
1193 80106605 2020-02-24 stsp .Ar commit .
1194 80106605 2020-02-24 stsp The expected
1195 80106605 2020-02-24 stsp .Ar commit
1196 80106605 2020-02-24 stsp argument is a commit ID SHA1 hash or an existing reference or tag name which
1197 80106605 2020-02-24 stsp will be resolved to a commit ID.
1198 80106605 2020-02-24 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1199 80106605 2020-02-24 stsp automatically, provided the abbreviation is unique.
1200 8e7bd50a 2019-08-22 stsp .It Fl m Ar message
1201 80106605 2020-02-24 stsp Use the specified tag message when creating the new tag.
1202 8e7bd50a 2019-08-22 stsp Without the
1205 3a62228f 2019-11-08 stsp .Cm got tag
1206 8e7bd50a 2019-08-22 stsp opens a temporary file in an editor where a tag message can be written.
1207 8e7bd50a 2019-08-22 stsp .It Fl r Ar repository-path
1208 8e7bd50a 2019-08-22 stsp Use the repository at the specified path.
1209 8e7bd50a 2019-08-22 stsp If not specified, assume the repository is located at or above the current
1210 8e7bd50a 2019-08-22 stsp working directory.
1211 8e7bd50a 2019-08-22 stsp If this directory is a
1213 8e7bd50a 2019-08-22 stsp work tree, use the repository path associated with this work tree.
1215 8e7bd50a 2019-08-22 stsp List all existing tags in the repository instead of creating a new tag.
1216 8e7bd50a 2019-08-22 stsp If this option is used, no other command-line arguments are allowed.
1219 8e7bd50a 2019-08-22 stsp By design, the
1220 8e7bd50a 2019-08-22 stsp .Cm got tag
1221 8e7bd50a 2019-08-22 stsp command will not delete tags or change existing tags.
1222 8e7bd50a 2019-08-22 stsp If a tag must be deleted, the
1223 8e7bd50a 2019-08-22 stsp .Cm got ref
1224 8e7bd50a 2019-08-22 stsp command may be used to delete a tag's reference.
1225 8e7bd50a 2019-08-22 stsp This should only be done if the tag has not already been copied to
1226 8e7bd50a 2019-08-22 stsp another repository.
1227 022fae89 2019-12-06 tracey .It Cm add Oo Fl R Oc Oo Fl I Oc Ar path ...
1228 8125ddca 2019-05-11 stsp Schedule unversioned files in a work tree for addition to the
1229 d00136be 2019-03-26 stsp repository in the next commit.
1230 ff56836b 2021-07-08 stsp By default, files which match a
1231 ff56836b 2021-07-08 stsp .Cm got status
1232 ff56836b 2021-07-08 stsp ignore pattern will not be added.
1234 4e68cba3 2019-11-23 stsp The options for
1235 4e68cba3 2019-11-23 stsp .Cm got add
1236 4e68cba3 2019-11-23 stsp are as follows:
1237 4e68cba3 2019-11-23 stsp .Bl -tag -width Ds
1239 4e68cba3 2019-11-23 stsp Permit recursion into directories.
1240 4e68cba3 2019-11-23 stsp If this option is not specified,
1241 4e68cba3 2019-11-23 stsp .Cm got add
1242 4e68cba3 2019-11-23 stsp will refuse to run if a specified
1244 4e68cba3 2019-11-23 stsp is a directory.
1245 022fae89 2019-12-06 tracey .It Fl I
1246 ff56836b 2021-07-08 stsp Add files even if they match a
1247 022fae89 2019-12-06 tracey .Cm got status
1248 022fae89 2019-12-06 tracey ignore pattern.
1251 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 ...
1252 d912d125 2021-11-04 thomas .Dl Pq alias: Cm rm
1253 17ed4618 2019-06-02 stsp Remove versioned files from a work tree and schedule them for deletion
1254 2ec1f75b 2019-03-26 stsp from the repository in the next commit.
1256 2ec1f75b 2019-03-26 stsp The options for
1257 86d25a1b 2019-07-11 stsp .Cm got remove
1258 2ec1f75b 2019-03-26 stsp are as follows:
1259 2ec1f75b 2019-03-26 stsp .Bl -tag -width Ds
1261 d64cc78a 2022-01-25 thomas Perform the operation even if a file contains local modifications,
1262 d64cc78a 2022-01-25 thomas and do not raise an error if a specified
1263 d64cc78a 2022-01-25 thomas .Ar path
1264 d64cc78a 2022-01-25 thomas does not exist on disk.
1265 70e3e7f5 2019-12-13 tracey .It Fl k
1266 70e3e7f5 2019-12-13 tracey Keep affected files on disk.
1267 f2a9dc41 2019-12-13 tracey .It Fl R
1268 f2a9dc41 2019-12-13 tracey Permit recursion into directories.
1269 f2a9dc41 2019-12-13 tracey If this option is not specified,
1270 f2a9dc41 2019-12-13 tracey .Cm got remove
1271 f2a9dc41 2019-12-13 tracey will refuse to run if a specified
1272 f2a9dc41 2019-12-13 tracey .Ar path
1273 f2a9dc41 2019-12-13 tracey is a directory.
1274 766841c2 2020-08-13 stsp .It Fl s Ar status-codes
1275 766841c2 2020-08-13 stsp Only delete files with a modification status matching one of the
1276 766841c2 2020-08-13 stsp single-character status codes contained in the
1277 766841c2 2020-08-13 stsp .Ar status-codes
1279 766841c2 2020-08-13 stsp The following status codes may be specified:
1280 766841c2 2020-08-13 stsp .Bl -column YXZ description
1281 766841c2 2020-08-13 stsp .It M Ta modified file (this implies the
1284 766841c2 2020-08-13 stsp .It ! Ta versioned file expected on disk but missing
1288 bfc91212 2022-03-13 thomas .It Cm patch Oo Fl n Oc Op Ar patchfile
1289 069bbb86 2022-03-07 thomas .Dl Pq alias: Cm pa
1290 069bbb86 2022-03-07 thomas Apply changes from
1291 069bbb86 2022-03-07 thomas .Ar patchfile
1292 07f74738 2022-03-13 thomas to files in a work tree.
1293 443c08c9 2022-03-13 thomas Files added or removed by a patch will be scheduled for addition or removal in
1294 443c08c9 2022-03-13 thomas the work tree.
1296 07f74738 2022-03-13 thomas The patch must be in the unified diff format as produced by
1297 07f74738 2022-03-13 thomas .Cm got diff ,
1298 99e34129 2022-03-22 thomas .Xr git-diff 1 ,
1300 07f74738 2022-03-13 thomas .Xr diff 1
1302 3eb4f629 2022-03-22 thomas .Xr cvs 1
1303 6f7394ad 2022-03-22 thomas diff when invoked with their
1305 6f7394ad 2022-03-22 thomas options.
1307 069bbb86 2022-03-07 thomas .Ar patchfile
1308 07f74738 2022-03-13 thomas argument is provided, read unified diff data from standard input instead.
1311 07f74738 2022-03-13 thomas .Ar patchfile
1312 4b06140e 2022-03-22 thomas contains multiple patches, then attempt to apply each of them in sequence.
1314 4929098b 2022-03-13 thomas Show the status of each affected file, using the following status codes:
1315 069bbb86 2022-03-07 thomas .Bl -column XYZ description
1316 07f74738 2022-03-13 thomas .It M Ta file was modified
1317 07f74738 2022-03-13 thomas .It D Ta file was deleted
1318 07f74738 2022-03-13 thomas .It A Ta file was added
1319 49114f01 2022-03-22 thomas .It # Ta failed to patch the file
1322 07f74738 2022-03-13 thomas If a change does not match at its exact line number, attempt to
1323 4929098b 2022-03-13 thomas apply it somewhere else in the file if a good spot can be found.
1324 4929098b 2022-03-13 thomas Otherwise, the patch will fail to apply.
1327 2cfc25ac 2022-03-13 thomas .Cm patch
1328 2cfc25ac 2022-03-13 thomas will refuse to apply a patch if certain preconditions are not met.
1329 4929098b 2022-03-13 thomas Files to be deleted must already be under version control, and must
1330 4929098b 2022-03-13 thomas not have been scheduled for deletion already.
1331 4929098b 2022-03-13 thomas Files to be added must not yet be under version control and must not
1332 4929098b 2022-03-13 thomas already be present on disk.
1333 4929098b 2022-03-13 thomas Files to be modified must already be under version control and may not
1334 4929098b 2022-03-13 thomas contain conflict markers.
1336 2cfc25ac 2022-03-13 thomas If an error occurs, the
1337 2cfc25ac 2022-03-13 thomas .Cm patch
1338 2cfc25ac 2022-03-13 thomas operation will be aborted.
1339 2cfc25ac 2022-03-13 thomas Any changes made to the work tree up to this point will be left behind.
1340 07f74738 2022-03-13 thomas Such changes can be viewed with
1341 2cfc25ac 2022-03-13 thomas .Cm got diff
1342 2cfc25ac 2022-03-13 thomas and can be reverted with
1343 2cfc25ac 2022-03-13 thomas .Cm got revert
1344 2cfc25ac 2022-03-13 thomas if needed.
1346 bfc91212 2022-03-13 thomas The options for
1347 bfc91212 2022-03-13 thomas .Cm got patch
1348 bfc91212 2022-03-13 thomas are as follows:
1349 bfc91212 2022-03-13 thomas .Bl -tag -width Ds
1350 bfc91212 2022-03-13 thomas .It Fl n
1351 bfc91212 2022-03-13 thomas Do not make any modifications to the work tree.
1352 bfc91212 2022-03-13 thomas This can be used to check whether a patch would apply without issues.
1354 bfc91212 2022-03-13 thomas .Ar patchfile
1355 4b06140e 2022-03-22 thomas contains diffs that affect the same file multiple times, the results
1356 bfc91212 2022-03-13 thomas displayed may be incorrect.
1359 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 ...
1360 d912d125 2021-11-04 thomas .Dl Pq alias: Cm rv
1361 bd81cfb7 2020-04-19 stsp Revert any local changes in files at the specified paths in a work tree.
1362 a129376b 2019-03-28 stsp File contents will be overwritten with those contained in the
1363 1dd86744 2019-08-12 anthony work tree's base commit.
1364 1dd86744 2019-08-12 anthony There is no way to bring discarded changes back after
1365 a129376b 2019-03-28 stsp .Cm got revert !
1367 e20a8b6f 2019-06-04 stsp If a file was added with
1368 4b06140e 2022-03-22 thomas .Cm got add ,
1369 a129376b 2019-03-28 stsp it will become an unversioned file again.
1370 e20a8b6f 2019-06-04 stsp If a file was deleted with
1371 4b06140e 2022-03-22 thomas .Cm got remove ,
1372 a129376b 2019-03-28 stsp it will be restored.
1374 0f6d7415 2019-08-08 stsp The options for
1375 0f6d7415 2019-08-08 stsp .Cm got revert
1376 0f6d7415 2019-08-08 stsp are as follows:
1377 0f6d7415 2019-08-08 stsp .Bl -tag -width Ds
1379 33aa809d 2019-08-08 stsp Instead of reverting all changes in files, interactively select or reject
1380 33aa809d 2019-08-08 stsp changes to revert based on
1382 33aa809d 2019-08-08 stsp (revert change),
1384 33aa809d 2019-08-08 stsp (keep change), and
1386 33aa809d 2019-08-08 stsp (quit reverting this file) responses.
1387 33aa809d 2019-08-08 stsp If a file is in modified status, individual patches derived from the
1388 33aa809d 2019-08-08 stsp modified file content can be reverted.
1389 33aa809d 2019-08-08 stsp Files in added or deleted status may only be reverted in their entirety.
1390 33aa809d 2019-08-08 stsp .It Fl F Ar response-script
1393 33aa809d 2019-08-08 stsp option, read
1398 33aa809d 2019-08-08 stsp responses line-by-line from the specified
1399 33aa809d 2019-08-08 stsp .Ar response-script
1400 33aa809d 2019-08-08 stsp file instead of prompting interactively.
1402 0f6d7415 2019-08-08 stsp Permit recursion into directories.
1403 0f6d7415 2019-08-08 stsp If this option is not specified,
1404 0f6d7415 2019-08-08 stsp .Cm got revert
1405 0f6d7415 2019-08-08 stsp will refuse to run if a specified
1407 0f6d7415 2019-08-08 stsp is a directory.
1410 28cf319f 2021-01-28 stsp .It Cm commit Oo Fl F Ar path Oc Oo Fl m Ar message Oc Oo Fl N Oc Oo Fl S Oc Op Ar path ...
1411 d912d125 2021-11-04 thomas .Dl Pq alias: Cm ci
1412 4ed9f614 2019-08-04 stsp Create a new commit in the repository from changes in a work tree
1413 15cd91f7 2019-05-12 stsp and use this commit as the new base commit for the work tree.
1416 4ed9f614 2019-08-04 stsp is specified, commit all changes in the work tree.
1417 4ed9f614 2019-08-04 stsp Otherwise, commit changes at or within the specified paths.
1419 4ed9f614 2019-08-04 stsp If changes have been explicitly staged for commit with
1420 1dd86744 2019-08-12 anthony .Cm got stage ,
1421 4ed9f614 2019-08-04 stsp only commit staged changes and reject any specified paths which
1422 4ed9f614 2019-08-04 stsp have not been staged.
1424 28cf319f 2021-01-28 stsp .Cm got commit
1425 28cf319f 2021-01-28 stsp opens a temporary file in an editor where a log message can be written
1426 28cf319f 2021-01-28 stsp unless the
1428 28cf319f 2021-01-28 stsp option is used
1433 28cf319f 2021-01-28 stsp options are used together.
1435 15cd91f7 2019-05-12 stsp Show the status of each affected file, using the following status codes:
1436 15cd91f7 2019-05-12 stsp .Bl -column YXZ description
1437 15cd91f7 2019-05-12 stsp .It M Ta modified file
1438 15cd91f7 2019-05-12 stsp .It D Ta file was deleted
1439 15cd91f7 2019-05-12 stsp .It A Ta new file was added
1440 1ebedb77 2019-10-19 stsp .It m Ta modified file modes (executable bit only)
1443 996d5ccd 2019-08-05 stsp Files which are not part of the new commit will retain their previously
1444 996d5ccd 2019-08-05 stsp recorded base commit.
1447 15cd91f7 2019-05-12 stsp commands may refuse to run while the work tree contains files from
1448 15cd91f7 2019-05-12 stsp multiple base commits.
1449 15cd91f7 2019-05-12 stsp The base commit of such a work tree can be made consistent by running
1450 47ec7be7 2019-05-12 stsp .Cm got update
1451 47ec7be7 2019-05-12 stsp across the entire work tree.
1454 15cd91f7 2019-05-12 stsp .Cm got commit
1455 15cd91f7 2019-05-12 stsp command requires the
1456 74416c47 2019-05-09 stsp .Ev GOT_AUTHOR
1457 aba9c984 2019-09-08 stsp environment variable to be set,
1458 257add31 2020-09-09 stsp unless an author has been configured in
1459 257add31 2020-09-09 stsp .Xr got.conf 5
1461 aba9c984 2019-09-08 stsp .Dv user.name
1463 709ae9eb 2019-09-08 stsp .Dv user.email
1464 709ae9eb 2019-09-08 stsp configuration settings can be
1465 aba9c984 2019-09-08 stsp obtained from the repository's
1466 aba9c984 2019-09-08 stsp .Pa .git/config
1467 c9956ddf 2019-09-08 stsp file or from Git's global
1468 c9956ddf 2019-09-08 stsp .Pa ~/.gitconfig
1469 c9956ddf 2019-09-08 stsp configuration file.
1471 74416c47 2019-05-09 stsp The options for
1472 74416c47 2019-05-09 stsp .Cm got commit
1473 74416c47 2019-05-09 stsp are as follows:
1474 74416c47 2019-05-09 stsp .Bl -tag -width Ds
1475 28cf319f 2021-01-28 stsp .It Fl F Ar path
1476 28cf319f 2021-01-28 stsp Use the prepared log message stored in the file found at
1478 28cf319f 2021-01-28 stsp when creating the new commit.
1479 28cf319f 2021-01-28 stsp .Cm got commit
1480 28cf319f 2021-01-28 stsp opens a temporary file in an editor where the prepared log message can be
1481 28cf319f 2021-01-28 stsp reviewed and edited further if needed.
1482 28cf319f 2021-01-28 stsp Cannot be used together with the
1485 28cf319f 2021-01-28 stsp .It Fl m Ar message
1486 28cf319f 2021-01-28 stsp Use the specified log message when creating the new commit.
1487 28cf319f 2021-01-28 stsp Cannot be used together with the
1491 28cf319f 2021-01-28 stsp This option prevents
1492 23594da9 2019-05-13 stsp .Cm got commit
1493 28cf319f 2021-01-28 stsp from opening the commit message in an editor.
1494 28cf319f 2021-01-28 stsp It has no effect unless it is used together with the
1496 28cf319f 2021-01-28 stsp option and is intended for non-interactive use such as scripting.
1498 af358f55 2020-07-23 stsp Allow the addition of symbolic links which point outside of the path space
1499 af358f55 2020-07-23 stsp that is under version control.
1500 af358f55 2020-07-23 stsp By default,
1501 af358f55 2020-07-23 stsp .Cm got commit
1502 af358f55 2020-07-23 stsp will reject such symbolic links due to safety concerns.
1503 35213c7c 2020-07-23 stsp As a precaution,
1505 af358f55 2020-07-23 stsp may decide to represent such a symbolic link as a regular file which contains
1506 af358f55 2020-07-23 stsp the link's target path, rather than creating an actual symbolic link which
1507 af358f55 2020-07-23 stsp points outside of the work tree.
1508 af358f55 2020-07-23 stsp Use of this option is discouraged because external mechanisms such as
1509 af358f55 2020-07-23 stsp .Dq make obj
1510 af358f55 2020-07-23 stsp are better suited for managing symbolic links to paths not under
1511 af358f55 2020-07-23 stsp version control.
1514 cfce0458 2019-07-28 stsp .Cm got commit
1515 cfce0458 2019-07-28 stsp will refuse to run if certain preconditions are not met.
1516 916f288c 2019-07-30 stsp If the work tree's current branch is not in the
1517 916f288c 2019-07-30 stsp .Dq refs/heads/
1518 916f288c 2019-07-30 stsp reference namespace, new commits may not be created on this branch.
1519 cfce0458 2019-07-28 stsp Local changes may only be committed if they are based on file content
1520 cfce0458 2019-07-28 stsp found in the most recent commit on the work tree's branch.
1521 cfce0458 2019-07-28 stsp If a path is found to be out of date,
1522 cfce0458 2019-07-28 stsp .Cm got update
1523 cfce0458 2019-07-28 stsp must be used first in order to merge local changes with changes made
1524 cfce0458 2019-07-28 stsp in the repository.
1526 f8a36e22 2021-08-26 stsp .It Cm send Oo Fl a Oc Oo Fl b Ar branch Oc Oo Fl d Ar branch Oc Oo Fl f Oc Oo Fl r Ar repository-path Oc Oo Fl t Ar tag Oc Oo Fl T Oc Oo Fl q Oc Oo Fl v Oc Op Ar remote-repository
1527 d912d125 2021-11-04 thomas .Dl Pq alias: Cm se
1528 f8a36e22 2021-08-26 stsp Send new changes to a remote repository.
1530 f8a36e22 2021-08-26 stsp .Ar remote-repository
1531 f8a36e22 2021-08-26 stsp is specified,
1532 f8a36e22 2021-08-26 stsp .Dq origin
1533 f8a36e22 2021-08-26 stsp will be used.
1534 f8a36e22 2021-08-26 stsp The remote repository's URL is obtained from the corresponding entry in
1535 f8a36e22 2021-08-26 stsp .Xr got.conf 5
1537 f8a36e22 2021-08-26 stsp .Pa config
1538 f8a36e22 2021-08-26 stsp file of the local repository, as created by
1539 f8a36e22 2021-08-26 stsp .Cm got clone .
1541 f8a36e22 2021-08-26 stsp All objects corresponding to new changes will be written to a temporary
1542 f8a36e22 2021-08-26 stsp pack file which is then uploaded to the server.
1543 f8a36e22 2021-08-26 stsp Upon success, references in the
1544 f8a36e22 2021-08-26 stsp .Dq refs/remotes/
1545 f8a36e22 2021-08-26 stsp reference namespace of the local repository will be updated to point at
1546 f8a36e22 2021-08-26 stsp the commits which have been sent.
1548 f8a36e22 2021-08-26 stsp By default, changes will only be sent if they are based on up-to-date
1549 f8a36e22 2021-08-26 stsp copies of relevant branches in the remote repository.
1550 fd44090b 2021-08-26 stsp If any changes to be sent are based on out-of-date copies or would
1551 fd44090b 2021-08-26 stsp otherwise break linear history of existing branches, new changes must
1552 fd44090b 2021-08-26 stsp be fetched from the server with
1553 f8a36e22 2021-08-26 stsp .Cm got fetch
1554 f8a36e22 2021-08-26 stsp and local branches must be rebased with
1555 f8a36e22 2021-08-26 stsp .Cm got rebase
1557 f8a36e22 2021-08-26 stsp .Cm got send
1558 f8a36e22 2021-08-26 stsp can succeed.
1561 fd44090b 2021-08-26 stsp option can be used to make exceptions to these requirements.
1563 f8a36e22 2021-08-26 stsp The options for
1564 f8a36e22 2021-08-26 stsp .Cm got send
1565 f8a36e22 2021-08-26 stsp are as follows:
1566 f8a36e22 2021-08-26 stsp .Bl -tag -width Ds
1568 f8a36e22 2021-08-26 stsp Send all branches from the local repository's
1569 f8a36e22 2021-08-26 stsp .Dq refs/heads/
1570 f8a36e22 2021-08-26 stsp reference namespace.
1573 f8a36e22 2021-08-26 stsp option is equivalent to listing all branches with multiple
1576 f8a36e22 2021-08-26 stsp Cannot be used together with the
1579 f8a36e22 2021-08-26 stsp .It Fl b Ar branch
1580 f8a36e22 2021-08-26 stsp Send the specified
1581 f8a36e22 2021-08-26 stsp .Ar branch
1582 f8a36e22 2021-08-26 stsp from the local repository's
1583 f8a36e22 2021-08-26 stsp .Dq refs/heads/
1584 f8a36e22 2021-08-26 stsp reference namespace.
1585 f8a36e22 2021-08-26 stsp This option may be specified multiple times to build a list of branches
1587 f8a36e22 2021-08-26 stsp If this option is not specified, default to the work tree's current branch
1588 f8a36e22 2021-08-26 stsp if invoked in a work tree, or to the repository's HEAD reference.
1589 f8a36e22 2021-08-26 stsp Cannot be used together with the
1592 f8a36e22 2021-08-26 stsp .It Fl d Ar branch
1593 f8a36e22 2021-08-26 stsp Delete the specified
1594 f8a36e22 2021-08-26 stsp .Ar branch
1595 f8a36e22 2021-08-26 stsp from the remote repository's
1596 f8a36e22 2021-08-26 stsp .Dq refs/heads/
1597 f8a36e22 2021-08-26 stsp reference namespace.
1598 f8a36e22 2021-08-26 stsp This option may be specified multiple times to build a list of branches
1599 f8a36e22 2021-08-26 stsp to delete.
1601 f8a36e22 2021-08-26 stsp Only references are deleted.
1602 f8a36e22 2021-08-26 stsp Any commit, tree, tag, and blob objects belonging to deleted branches
1603 f8a36e22 2021-08-26 stsp may become subject to deletion by Git's garbage collector running on
1604 f8a36e22 2021-08-26 stsp the server.
1606 f8a36e22 2021-08-26 stsp Requesting deletion of branches results in an error if the server
1607 fd44090b 2021-08-26 stsp does not support this feature or disallows the deletion of branches
1608 fd44090b 2021-08-26 stsp based on its configuration.
1610 fd44090b 2021-08-26 stsp Attempt to force the server to overwrite existing branches or tags
1611 fd44090b 2021-08-26 stsp in the remote repository, even when
1612 fd44090b 2021-08-26 stsp .Cm got fetch
1614 fd44090b 2021-08-26 stsp .Cm got rebase
1615 fd44090b 2021-08-26 stsp would usually be required before changes can be sent.
1616 f8a36e22 2021-08-26 stsp The server may reject forced requests regardless, depending on its
1617 f8a36e22 2021-08-26 stsp configuration.
1619 f8a36e22 2021-08-26 stsp Any commit, tree, tag, and blob objects belonging to overwritten branches
1620 f8a36e22 2021-08-26 stsp or tags may become subject to deletion by Git's garbage collector running
1621 f8a36e22 2021-08-26 stsp on the server.
1624 f8a36e22 2021-08-26 stsp .Dq refs/tags
1625 f8a36e22 2021-08-26 stsp reference namespace is globally shared between all repositories.
1626 f8a36e22 2021-08-26 stsp Use of the
1628 f8a36e22 2021-08-26 stsp option to overwrite tags is discouraged because it can lead to
1629 f8a36e22 2021-08-26 stsp inconsistencies between the tags present in different repositories.
1630 f8a36e22 2021-08-26 stsp In general, creating a new tag with a different name is recommended
1631 f8a36e22 2021-08-26 stsp instead of overwriting an existing tag.
1633 f8a36e22 2021-08-26 stsp Use of the
1635 f8a36e22 2021-08-26 stsp option is particularly discouraged if changes being sent are based
1636 f8a36e22 2021-08-26 stsp on an out-of-date copy of a branch in the remote repository.
1637 f8a36e22 2021-08-26 stsp Instead of using the
1639 f8a36e22 2021-08-26 stsp option, new changes should
1640 f8a36e22 2021-08-26 stsp be fetched with
1641 f8a36e22 2021-08-26 stsp .Cm got fetch
1642 f8a36e22 2021-08-26 stsp and local branches should be rebased with
1643 f8a36e22 2021-08-26 stsp .Cm got rebase ,
1644 f8a36e22 2021-08-26 stsp followed by another attempt to send the changes.
1648 f8a36e22 2021-08-26 stsp option should only be needed in situations where the remote repository's
1649 f8a36e22 2021-08-26 stsp copy of a branch or tag is known to be out-of-date and is considered
1650 f8a36e22 2021-08-26 stsp disposable.
1651 f8a36e22 2021-08-26 stsp The risks of creating inconsistencies between different repositories
1652 f8a36e22 2021-08-26 stsp should also be taken into account.
1653 f8a36e22 2021-08-26 stsp .It Fl r Ar repository-path
1654 f8a36e22 2021-08-26 stsp Use the repository at the specified path.
1655 f8a36e22 2021-08-26 stsp If not specified, assume the repository is located at or above the current
1656 f8a36e22 2021-08-26 stsp working directory.
1657 f8a36e22 2021-08-26 stsp If this directory is a
1659 f8a36e22 2021-08-26 stsp work tree, use the repository path associated with this work tree.
1660 f8a36e22 2021-08-26 stsp .It Fl t Ar tag
1661 f8a36e22 2021-08-26 stsp Send the specified
1663 f8a36e22 2021-08-26 stsp from the local repository's
1664 f8a36e22 2021-08-26 stsp .Dq refs/tags/
1665 f8a36e22 2021-08-26 stsp reference namespace, in addition to any branches that are being sent.
1668 f8a36e22 2021-08-26 stsp option may be specified multiple times to build a list of tags to send.
1669 f8a36e22 2021-08-26 stsp No tags will be sent if the
1671 f8a36e22 2021-08-26 stsp option is not used.
1673 f8a36e22 2021-08-26 stsp Raise an error if the specified
1675 f8a36e22 2021-08-26 stsp already exists in the remote repository, unless the
1677 93a300b2 2021-08-26 stsp option is used to overwrite the server's copy of the tag.
1678 f8a36e22 2021-08-26 stsp In general, creating a new tag with a different name is recommended
1679 f8a36e22 2021-08-26 stsp instead of overwriting an existing tag.
1681 f8a36e22 2021-08-26 stsp Cannot be used together with the
1685 f8a36e22 2021-08-26 stsp Attempt to send all tags from the local repository's
1686 f8a36e22 2021-08-26 stsp .Dq refs/tags/
1687 f8a36e22 2021-08-26 stsp reference namespace.
1690 f8a36e22 2021-08-26 stsp option is equivalent to listing all tags with multiple
1693 f8a36e22 2021-08-26 stsp Cannot be used together with the
1697 f8a36e22 2021-08-26 stsp Suppress progress reporting output.
1698 f8a36e22 2021-08-26 stsp The same option will be passed to
1700 f8a36e22 2021-08-26 stsp if applicable.
1702 f8a36e22 2021-08-26 stsp Verbose mode.
1704 f8a36e22 2021-08-26 stsp .Cm got send
1705 f8a36e22 2021-08-26 stsp to print debugging messages to standard error output.
1706 f8a36e22 2021-08-26 stsp The same option will be passed to
1708 f8a36e22 2021-08-26 stsp if applicable.
1709 f8a36e22 2021-08-26 stsp Multiple -v options increase the verbosity.
1710 f8a36e22 2021-08-26 stsp The maximum is 3.
1713 234035bc 2019-06-01 stsp .It Cm cherrypick Ar commit
1714 d912d125 2021-11-04 thomas .Dl Pq alias: Cm cy
1715 234035bc 2019-06-01 stsp Merge changes from a single
1716 234035bc 2019-06-01 stsp .Ar commit
1717 234035bc 2019-06-01 stsp into the work tree.
1718 234035bc 2019-06-01 stsp The specified
1719 234035bc 2019-06-01 stsp .Ar commit
1720 a16d97bd 2021-09-02 stsp should be on a different branch than the work tree's base commit.
1721 a54b6686 2019-06-28 stsp The expected argument is a reference or a commit ID SHA1 hash.
1722 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1723 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
1725 234035bc 2019-06-01 stsp Show the status of each affected file, using the following status codes:
1726 234035bc 2019-06-01 stsp .Bl -column YXZ description
1727 234035bc 2019-06-01 stsp .It G Ta file was merged
1728 234035bc 2019-06-01 stsp .It C Ta file was merged and conflicts occurred during merge
1729 234035bc 2019-06-01 stsp .It ! Ta changes destined for a missing file were not merged
1730 234035bc 2019-06-01 stsp .It D Ta file was deleted
1731 df3d7c3e 2021-09-24 thomas .It d Ta file's deletion was prevented by local modifications
1732 234035bc 2019-06-01 stsp .It A Ta new file was added
1733 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1734 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
1737 234035bc 2019-06-01 stsp The merged changes will appear as local changes in the work tree, which
1738 234035bc 2019-06-01 stsp may be viewed with
1739 234035bc 2019-06-01 stsp .Cm got diff ,
1740 234035bc 2019-06-01 stsp amended manually or with further
1741 234035bc 2019-06-01 stsp .Cm got cherrypick
1743 234035bc 2019-06-01 stsp committed with
1744 234035bc 2019-06-01 stsp .Cm got commit ,
1745 234035bc 2019-06-01 stsp or discarded again with
1746 234035bc 2019-06-01 stsp .Cm got revert .
1748 234035bc 2019-06-01 stsp .Cm got cherrypick
1749 234035bc 2019-06-01 stsp will refuse to run if certain preconditions are not met.
1750 4b06140e 2022-03-22 thomas If the work tree contains multiple base commits, it must first be updated
1751 234035bc 2019-06-01 stsp to a single base commit with
1752 234035bc 2019-06-01 stsp .Cm got update .
1753 69de9dd4 2021-09-03 stsp If any relevant files already contain merge conflicts, these
1754 234035bc 2019-06-01 stsp conflicts must be resolved first.
1756 5ef14e63 2019-06-02 stsp .It Cm backout Ar commit
1757 d912d125 2021-11-04 thomas .Dl Pq alias: Cm bo
1758 5ef14e63 2019-06-02 stsp Reverse-merge changes from a single
1759 5ef14e63 2019-06-02 stsp .Ar commit
1760 5ef14e63 2019-06-02 stsp into the work tree.
1761 5ef14e63 2019-06-02 stsp The specified
1762 5ef14e63 2019-06-02 stsp .Ar commit
1763 a16d97bd 2021-09-02 stsp should be on the same branch as the work tree's base commit.
1764 a54b6686 2019-06-28 stsp The expected argument is a reference or a commit ID SHA1 hash.
1765 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
1766 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
1768 5ef14e63 2019-06-02 stsp Show the status of each affected file, using the following status codes:
1769 5ef14e63 2019-06-02 stsp .Bl -column YXZ description
1770 5ef14e63 2019-06-02 stsp .It G Ta file was merged
1771 5ef14e63 2019-06-02 stsp .It C Ta file was merged and conflicts occurred during merge
1772 5ef14e63 2019-06-02 stsp .It ! Ta changes destined for a missing file were not merged
1773 5ef14e63 2019-06-02 stsp .It D Ta file was deleted
1774 df3d7c3e 2021-09-24 thomas .It d Ta file's deletion was prevented by local modifications
1775 5ef14e63 2019-06-02 stsp .It A Ta new file was added
1776 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1777 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
1780 5ef14e63 2019-06-02 stsp The reverse-merged changes will appear as local changes in the work tree,
1781 5ef14e63 2019-06-02 stsp which may be viewed with
1782 5ef14e63 2019-06-02 stsp .Cm got diff ,
1783 5ef14e63 2019-06-02 stsp amended manually or with further
1784 778a73c2 2019-07-12 stsp .Cm got backout
1786 5ef14e63 2019-06-02 stsp committed with
1787 5ef14e63 2019-06-02 stsp .Cm got commit ,
1788 5ef14e63 2019-06-02 stsp or discarded again with
1789 5ef14e63 2019-06-02 stsp .Cm got revert .
1791 92228c38 2019-06-02 stsp .Cm got backout
1792 92228c38 2019-06-02 stsp will refuse to run if certain preconditions are not met.
1793 4b06140e 2022-03-22 thomas If the work tree contains multiple base commits, it must first be updated
1794 92228c38 2019-06-02 stsp to a single base commit with
1795 92228c38 2019-06-02 stsp .Cm got update .
1796 69de9dd4 2021-09-03 stsp If any relevant files already contain merge conflicts, these
1797 92228c38 2019-06-02 stsp conflicts must be resolved first.
1799 643b85bc 2021-07-16 stsp .It Cm rebase Oo Fl a Oc Oo Fl c Oc Oo Fl l Oc Oo Fl X Oc Op Ar branch
1800 d912d125 2021-11-04 thomas .Dl Pq alias: Cm rb
1801 818c7501 2019-07-11 stsp Rebase commits on the specified
1802 818c7501 2019-07-11 stsp .Ar branch
1803 818c7501 2019-07-11 stsp onto the tip of the current branch of the work tree.
1805 818c7501 2019-07-11 stsp .Ar branch
1806 818c7501 2019-07-11 stsp must share common ancestry with the work tree's current branch.
1807 bc3056e3 2019-08-18 stsp Rebasing begins with the first descendant commit of the youngest
1808 f09e2405 2019-07-11 stsp common ancestor commit shared by the specified
1809 818c7501 2019-07-11 stsp .Ar branch
1810 818c7501 2019-07-11 stsp and the work tree's current branch, and stops once the tip commit
1811 f09e2405 2019-07-11 stsp of the specified
1812 818c7501 2019-07-11 stsp .Ar branch
1813 f09e2405 2019-07-11 stsp has been rebased.
1816 2b6826ba 2020-02-24 stsp .Cm got rebase
1817 2b6826ba 2020-02-24 stsp is used as intended, the specified
1818 2b6826ba 2020-02-24 stsp .Ar branch
1819 c10890ce 2020-02-25 stsp represents a local commit history and may already contain changes
1820 c10890ce 2020-02-25 stsp that are not yet visible in any other repositories.
1821 2b6826ba 2020-02-24 stsp The work tree's current branch, which must be set with
1822 2b6826ba 2020-02-24 stsp .Cm got update -b
1823 2b6826ba 2020-02-24 stsp before starting the
1824 2b6826ba 2020-02-24 stsp .Cm rebase
1825 2b6826ba 2020-02-24 stsp operation, represents a branch from a remote repository which shares
1826 2b6826ba 2020-02-24 stsp a common history with the specified
1827 2b6826ba 2020-02-24 stsp .Ar branch
1828 c10890ce 2020-02-25 stsp but has progressed, and perhaps diverged, due to commits added to the
1829 c10890ce 2020-02-25 stsp remote repository.
1831 c6b4581b 2019-07-28 stsp Rebased commits are accumulated on a temporary branch which the work tree
1832 c6b4581b 2019-07-28 stsp will remain switched to throughout the entire rebase operation.
1833 c6b4581b 2019-07-28 stsp Commits on this branch represent the same changes with the same log
1834 c6b4581b 2019-07-28 stsp messages as their counterparts on the original
1835 818c7501 2019-07-11 stsp .Ar branch ,
1836 818c7501 2019-07-11 stsp but with different commit IDs.
1837 818c7501 2019-07-11 stsp Once rebasing has completed successfully, the temporary branch becomes
1838 f09e2405 2019-07-11 stsp the new version of the specified
1839 818c7501 2019-07-11 stsp .Ar branch
1840 818c7501 2019-07-11 stsp and the work tree is automatically switched to it.
1842 1795b260 2021-04-02 kn Old commits in their pre-rebase state are automatically backed up in the
1843 e600f124 2021-03-21 stsp .Dq refs/got/backup/rebase
1844 e600f124 2021-03-21 stsp reference namespace.
1845 e600f124 2021-03-21 stsp As long as these references are not removed older versions of rebased
1846 e600f124 2021-03-21 stsp commits will remain in the repository and can be viewed with the
1847 e600f124 2021-03-21 stsp .Cm got rebase -l
1849 e600f124 2021-03-21 stsp Removal of these references makes objects which become unreachable via
1850 e6786710 2021-07-03 stsp any reference subject to removal by Git's garbage collector or
1851 e6786710 2021-07-03 stsp .Cm gotadmin cleanup .
1853 818c7501 2019-07-11 stsp While rebasing commits, show the status of each affected file,
1854 818c7501 2019-07-11 stsp using the following status codes:
1855 818c7501 2019-07-11 stsp .Bl -column YXZ description
1856 818c7501 2019-07-11 stsp .It G Ta file was merged
1857 818c7501 2019-07-11 stsp .It C Ta file was merged and conflicts occurred during merge
1858 818c7501 2019-07-11 stsp .It ! Ta changes destined for a missing file were not merged
1859 818c7501 2019-07-11 stsp .It D Ta file was deleted
1860 df3d7c3e 2021-09-24 thomas .It d Ta file's deletion was prevented by local modifications
1861 818c7501 2019-07-11 stsp .It A Ta new file was added
1862 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
1863 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
1866 4b06140e 2022-03-22 thomas If merge conflicts occur, the rebase operation is interrupted and may
1867 f09e2405 2019-07-11 stsp be continued once conflicts have been resolved.
1868 bb494413 2021-09-28 thomas If any files with destined changes are found to be missing or unversioned,
1869 bb494413 2021-09-28 thomas or if files could not be deleted due to differences in deleted content,
1870 bb494413 2021-09-28 thomas the rebase operation will be interrupted to prevent potentially incomplete
1871 bb494413 2021-09-28 thomas changes from being committed to the repository without user intervention.
1872 bb494413 2021-09-28 thomas The work tree may be modified as desired and the rebase operation can be
1873 bb494413 2021-09-28 thomas continued once the changes present in the work tree are considered complete.
1874 818c7501 2019-07-11 stsp Alternatively, the rebase operation may be aborted which will leave
1875 818c7501 2019-07-11 stsp .Ar branch
1876 818c7501 2019-07-11 stsp unmodified and the work tree switched back to its original branch.
1878 ff0d2220 2019-07-11 stsp If a merge conflict is resolved in a way which renders the merged
1879 f09e2405 2019-07-11 stsp change into a no-op change, the corresponding commit will be elided
1880 f09e2405 2019-07-11 stsp when the rebase operation continues.
1882 818c7501 2019-07-11 stsp .Cm got rebase
1883 818c7501 2019-07-11 stsp will refuse to run if certain preconditions are not met.
1884 a85446b2 2020-01-04 stsp If the work tree is not yet fully updated to the tip commit of its
1885 4b06140e 2022-03-22 thomas branch, then the work tree must first be updated with
1886 818c7501 2019-07-11 stsp .Cm got update .
1887 4ed9f614 2019-08-04 stsp If changes have been staged with
1888 4ed9f614 2019-08-04 stsp .Cm got stage ,
1889 bc3056e3 2019-08-18 stsp these changes must first be committed with
1890 4ed9f614 2019-08-04 stsp .Cm got commit
1891 4ed9f614 2019-08-04 stsp or unstaged with
1892 4ed9f614 2019-08-04 stsp .Cm got unstage .
1893 f09e2405 2019-07-11 stsp If the work tree contains local changes, these changes must first be
1894 f09e2405 2019-07-11 stsp committed with
1895 f09e2405 2019-07-11 stsp .Cm got commit
1896 f09e2405 2019-07-11 stsp or reverted with
1897 f09e2405 2019-07-11 stsp .Cm got revert .
1899 64c6d990 2019-07-11 stsp .Ar branch
1900 64c6d990 2019-07-11 stsp contains changes to files outside of the work tree's path prefix,
1901 64c6d990 2019-07-11 stsp the work tree cannot be used to rebase this branch.
1904 7d5807f4 2019-07-11 stsp .Cm got update
1906 7d5807f4 2019-07-11 stsp .Cm got commit
1907 7d5807f4 2019-07-11 stsp commands will refuse to run while a rebase operation is in progress.
1908 7d5807f4 2019-07-11 stsp Other commands which manipulate the work tree may be used for
1909 7d5807f4 2019-07-11 stsp conflict resolution purposes.
1911 d10218e7 2021-11-04 thomas If the specified
1912 d10218e7 2021-11-04 thomas .Ar branch
1913 4b06140e 2022-03-22 thomas is already based on the work tree's current branch, then no commits
1914 d10218e7 2021-11-04 thomas need to be rebased and
1915 d10218e7 2021-11-04 thomas .Cm got rebase
1916 d10218e7 2021-11-04 thomas will simply switch the work tree to the specified
1917 d10218e7 2021-11-04 thomas .Ar branch
1918 d10218e7 2021-11-04 thomas and update files in the work tree accordingly.
1920 818c7501 2019-07-11 stsp The options for
1921 818c7501 2019-07-11 stsp .Cm got rebase
1922 818c7501 2019-07-11 stsp are as follows:
1923 818c7501 2019-07-11 stsp .Bl -tag -width Ds
1925 818c7501 2019-07-11 stsp Abort an interrupted rebase operation.
1926 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
1928 06067b48 2019-07-11 stsp Continue an interrupted rebase operation.
1929 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
1931 e600f124 2021-03-21 stsp Show a list of past rebase operations, represented by references in the
1932 e600f124 2021-03-21 stsp .Dq refs/got/backup/rebase
1933 e600f124 2021-03-21 stsp reference namespace.
1935 e600f124 2021-03-21 stsp Display the author, date, and log message of each backed up commit,
1936 e600f124 2021-03-21 stsp the object ID of the corresponding post-rebase commit, and
1937 e600f124 2021-03-21 stsp the object ID of their common ancestor commit.
1938 e600f124 2021-03-21 stsp Given these object IDs,
1940 e600f124 2021-03-21 stsp .Cm got log
1941 e600f124 2021-03-21 stsp command with the
1945 e600f124 2021-03-21 stsp options can be used to examine the history of either version of the branch,
1947 e600f124 2021-03-21 stsp .Cm got branch
1948 e600f124 2021-03-21 stsp command with the
1950 e600f124 2021-03-21 stsp option can be used to create a new branch from a pre-rebase state if desired.
1953 e600f124 2021-03-21 stsp .Ar branch
1954 e600f124 2021-03-21 stsp is specified, only show commits which at some point in time represented this
1956 e600f124 2021-03-21 stsp Otherwise, list all backed up commits for any branches.
1958 e600f124 2021-03-21 stsp If this option is used,
1959 e600f124 2021-03-21 stsp .Cm got rebase
1960 e600f124 2021-03-21 stsp does not require a work tree.
1961 e600f124 2021-03-21 stsp None of the other options can be used together with
1964 643b85bc 2021-07-16 stsp Delete backups created by past rebase operations, represented by references
1966 643b85bc 2021-07-16 stsp .Dq refs/got/backup/rebase
1967 643b85bc 2021-07-16 stsp reference namespace.
1970 643b85bc 2021-07-16 stsp .Ar branch
1971 643b85bc 2021-07-16 stsp is specified, only delete backups which at some point in time represented
1972 643b85bc 2021-07-16 stsp this branch.
1973 643b85bc 2021-07-16 stsp Otherwise, delete all references found within
1974 643b85bc 2021-07-16 stsp .Dq refs/got/backup/rebase .
1976 643b85bc 2021-07-16 stsp Any commit, tree, tag, and blob objects belonging to deleted backups
1977 643b85bc 2021-07-16 stsp remain in the repository and may be removed separately with
1978 643b85bc 2021-07-16 stsp Git's garbage collector or
1979 643b85bc 2021-07-16 stsp .Cm gotadmin cleanup .
1981 643b85bc 2021-07-16 stsp If this option is used,
1982 643b85bc 2021-07-16 stsp .Cm got rebase
1983 643b85bc 2021-07-16 stsp does not require a work tree.
1984 643b85bc 2021-07-16 stsp None of the other options can be used together with
1988 c50a7455 2021-10-04 thomas .It Cm histedit Oo Fl a Oc Oo Fl c Oc Oo Fl e Oc Oo Fl f Oc Oo Fl F Ar histedit-script Oc Oo Fl m Oc Oo Fl l Oc Oo Fl X Oc Op Ar branch
1989 d912d125 2021-11-04 thomas .Dl Pq alias: Cm he
1990 0ebf8283 2019-07-24 stsp Edit commit history between the work tree's current base commit and
1991 0ebf8283 2019-07-24 stsp the tip commit of the work tree's current branch.
1993 6e54d307 2020-02-24 stsp Before starting a
1994 6e54d307 2020-02-24 stsp .Cm histedit
1995 4b06140e 2022-03-22 thomas operation, the work tree's current branch must be set with
1996 6e54d307 2020-02-24 stsp .Cm got update -b
1997 6e54d307 2020-02-24 stsp to the branch which should be edited, unless this branch is already the
1998 6e54d307 2020-02-24 stsp current branch of the work tree.
1999 6e54d307 2020-02-24 stsp The tip of this branch represents the upper bound (inclusive) of commits
2000 6e54d307 2020-02-24 stsp touched by the
2001 6e54d307 2020-02-24 stsp .Cm histedit
2002 6e54d307 2020-02-24 stsp operation.
2004 6e54d307 2020-02-24 stsp Furthermore, the work tree's base commit
2005 6e54d307 2020-02-24 stsp must be set with
2006 6e54d307 2020-02-24 stsp .Cm got update -c
2007 6e54d307 2020-02-24 stsp to a point in this branch's commit history where editing should begin.
2008 6e54d307 2020-02-24 stsp This commit represents the lower bound (non-inclusive) of commits touched
2010 6e54d307 2020-02-24 stsp .Cm histedit
2011 6e54d307 2020-02-24 stsp operation.
2013 0ebf8283 2019-07-24 stsp Editing of commit history is controlled via a
2014 0ebf8283 2019-07-24 stsp .Ar histedit script
2015 46fa4c83 2020-02-24 stsp which can be written in an editor based on a template, passed on the
2016 46fa4c83 2020-02-24 stsp command line, or generated with the
2022 0ebf8283 2019-07-24 stsp The format of the histedit script is line-based.
2023 0ebf8283 2019-07-24 stsp Each line in the script begins with a command name, followed by
2024 0ebf8283 2019-07-24 stsp whitespace and an argument.
2025 0ebf8283 2019-07-24 stsp For most commands, the expected argument is a commit ID SHA1 hash.
2026 0ebf8283 2019-07-24 stsp Any remaining text on the line is ignored.
2027 0ebf8283 2019-07-24 stsp Lines which begin with the
2029 0ebf8283 2019-07-24 stsp character are ignored entirely.
2031 0ebf8283 2019-07-24 stsp The available commands are as follows:
2032 0ebf8283 2019-07-24 stsp .Bl -column YXZ pick-commit
2033 0ebf8283 2019-07-24 stsp .It pick Ar commit Ta Use the specified commit as it is.
2034 a698f62e 2019-07-25 stsp .It edit Ar commit Ta Use the specified commit but once changes have been
2035 0ebf8283 2019-07-24 stsp merged into the work tree interrupt the histedit operation for amending.
2036 0ebf8283 2019-07-24 stsp .It fold Ar commit Ta Combine the specified commit with the next commit
2037 0ebf8283 2019-07-24 stsp listed further below that will be used.
2038 0ebf8283 2019-07-24 stsp .It drop Ar commit Ta Remove this commit from the edited history.
2039 0ebf8283 2019-07-24 stsp .It mesg Ar log-message Ta Use the specified single-line log message for
2040 0ebf8283 2019-07-24 stsp the commit on the previous line.
2041 0ebf8283 2019-07-24 stsp If the log message argument is left empty, open an editor where a new
2042 0ebf8283 2019-07-24 stsp log message can be written.
2045 ba67992e 2019-07-25 stsp Every commit in the history being edited must be mentioned in the script.
2046 0ebf8283 2019-07-24 stsp Lines may be re-ordered to change the order of commits in the edited history.
2047 5b87815e 2020-03-05 stsp No commit may be listed more than once.
2049 c6b4581b 2019-07-28 stsp Edited commits are accumulated on a temporary branch which the work tree
2050 c6b4581b 2019-07-28 stsp will remain switched to throughout the entire histedit operation.
2051 0ebf8283 2019-07-24 stsp Once history editing has completed successfully, the temporary branch becomes
2052 498a90b7 2019-07-25 stsp the new version of the work tree's branch and the work tree is automatically
2053 498a90b7 2019-07-25 stsp switched to it.
2055 1795b260 2021-04-02 kn Old commits in their pre-histedit state are automatically backed up in the
2056 e600f124 2021-03-21 stsp .Dq refs/got/backup/histedit
2057 e600f124 2021-03-21 stsp reference namespace.
2058 e600f124 2021-03-21 stsp As long as these references are not removed older versions of edited
2059 e600f124 2021-03-21 stsp commits will remain in the repository and can be viewed with the
2060 e600f124 2021-03-21 stsp .Cm got histedit -l
2062 e600f124 2021-03-21 stsp Removal of these references makes objects which become unreachable via
2063 e6786710 2021-07-03 stsp any reference subject to removal by Git's garbage collector or
2064 e6786710 2021-07-03 stsp .Cm gotadmin cleanup .
2066 0ebf8283 2019-07-24 stsp While merging commits, show the status of each affected file,
2067 0ebf8283 2019-07-24 stsp using the following status codes:
2068 0ebf8283 2019-07-24 stsp .Bl -column YXZ description
2069 0ebf8283 2019-07-24 stsp .It G Ta file was merged
2070 0ebf8283 2019-07-24 stsp .It C Ta file was merged and conflicts occurred during merge
2071 0ebf8283 2019-07-24 stsp .It ! Ta changes destined for a missing file were not merged
2072 0ebf8283 2019-07-24 stsp .It D Ta file was deleted
2073 df3d7c3e 2021-09-24 thomas .It d Ta file's deletion was prevented by local modifications
2074 0ebf8283 2019-07-24 stsp .It A Ta new file was added
2075 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
2076 c90c8ce3 2020-07-23 stsp .It ? Ta changes destined for an unversioned file were not merged
2079 4b06140e 2022-03-22 thomas If merge conflicts occur, the histedit operation is interrupted and may
2080 0ebf8283 2019-07-24 stsp be continued once conflicts have been resolved.
2081 dddbe150 2021-09-28 thomas If any files with destined changes are found to be missing or unversioned,
2082 dddbe150 2021-09-28 thomas or if files could not be deleted due to differences in deleted content,
2083 dddbe150 2021-09-28 thomas the histedit operation will be interrupted to prevent potentially incomplete
2084 dddbe150 2021-09-28 thomas changes from being committed to the repository without user intervention.
2085 dddbe150 2021-09-28 thomas The work tree may be modified as desired and the histedit operation can be
2086 dddbe150 2021-09-28 thomas continued once the changes present in the work tree are considered complete.
2087 0ebf8283 2019-07-24 stsp Alternatively, the histedit operation may be aborted which will leave
2088 0ebf8283 2019-07-24 stsp the work tree switched back to its original branch.
2090 0ebf8283 2019-07-24 stsp If a merge conflict is resolved in a way which renders the merged
2091 0ebf8283 2019-07-24 stsp change into a no-op change, the corresponding commit will be elided
2092 0ebf8283 2019-07-24 stsp when the histedit operation continues.
2094 0ebf8283 2019-07-24 stsp .Cm got histedit
2095 0ebf8283 2019-07-24 stsp will refuse to run if certain preconditions are not met.
2096 c7d20a3f 2019-07-30 stsp If the work tree's current branch is not in the
2097 c7d20a3f 2019-07-30 stsp .Dq refs/heads/
2098 c7d20a3f 2019-07-30 stsp reference namespace, the history of the branch may not be edited.
2099 4b06140e 2022-03-22 thomas If the work tree contains multiple base commits, it must first be updated
2100 0ebf8283 2019-07-24 stsp to a single base commit with
2101 0ebf8283 2019-07-24 stsp .Cm got update .
2102 4ed9f614 2019-08-04 stsp If changes have been staged with
2103 4ed9f614 2019-08-04 stsp .Cm got stage ,
2104 bc3056e3 2019-08-18 stsp these changes must first be committed with
2105 4ed9f614 2019-08-04 stsp .Cm got commit
2106 4ed9f614 2019-08-04 stsp or unstaged with
2107 4ed9f614 2019-08-04 stsp .Cm got unstage .
2108 0ebf8283 2019-07-24 stsp If the work tree contains local changes, these changes must first be
2109 0ebf8283 2019-07-24 stsp committed with
2110 0ebf8283 2019-07-24 stsp .Cm got commit
2111 0ebf8283 2019-07-24 stsp or reverted with
2112 0ebf8283 2019-07-24 stsp .Cm got revert .
2113 0ebf8283 2019-07-24 stsp If the edited history contains changes to files outside of the work tree's
2114 0ebf8283 2019-07-24 stsp path prefix, the work tree cannot be used to edit the history of this branch.
2117 7ef62c4e 2020-02-24 stsp .Cm got update ,
2118 7ef62c4e 2020-02-24 stsp .Cm got rebase ,
2120 65db4ffb 2020-02-24 stsp .Cm got integrate
2121 65db4ffb 2020-02-24 stsp commands will refuse to run while a histedit operation is in progress.
2122 a698f62e 2019-07-25 stsp Other commands which manipulate the work tree may be used, and the
2123 0ebf8283 2019-07-24 stsp .Cm got commit
2124 a698f62e 2019-07-25 stsp command may be used to commit arbitrary changes to the temporary branch
2125 a698f62e 2019-07-25 stsp while the histedit operation is interrupted.
2127 0ebf8283 2019-07-24 stsp The options for
2128 0ebf8283 2019-07-24 stsp .Cm got histedit
2129 0ebf8283 2019-07-24 stsp are as follows:
2130 0ebf8283 2019-07-24 stsp .Bl -tag -width Ds
2132 0ebf8283 2019-07-24 stsp Abort an interrupted histedit operation.
2133 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
2135 0ebf8283 2019-07-24 stsp Continue an interrupted histedit operation.
2136 c478f6d8 2019-08-08 stsp If this option is used, no other command-line arguments are allowed.
2137 c50a7455 2021-10-04 thomas .It Fl e
2138 c50a7455 2021-10-04 thomas Interrupt the histedit operation for editing after merging each commit.
2139 c50a7455 2021-10-04 thomas This option is a quick equivalent to a histedit script which uses the
2140 c50a7455 2021-10-04 thomas .Cm edit
2141 c50a7455 2021-10-04 thomas command for all commits.
2144 c50a7455 2021-10-04 thomas option can only be used when starting a new histedit operation.
2145 c50a7455 2021-10-04 thomas If this option is used, no other command-line arguments are allowed.
2147 466785b9 2020-12-10 jrick Fold all commits into a single commit.
2148 466785b9 2020-12-10 jrick This option is a quick equivalent to a histedit script which folds all
2149 466785b9 2020-12-10 jrick commits, combining them all into one commit.
2152 2a78779e 2020-12-11 stsp option can only be used when starting a new histedit operation.
2153 466785b9 2020-12-10 jrick If this option is used, no other command-line arguments are allowed.
2154 ddbfac99 2020-02-24 stsp .It Fl F Ar histedit-script
2155 ddbfac99 2020-02-24 stsp Use the specified
2156 ddbfac99 2020-02-24 stsp .Ar histedit-script
2157 ddbfac99 2020-02-24 stsp instead of opening a temporary file in an editor where a histedit script
2158 ddbfac99 2020-02-24 stsp can be written.
2160 083957f4 2020-02-24 stsp Edit log messages only.
2161 083957f4 2020-02-24 stsp This option is a quick equivalent to a histedit script which edits
2162 2bdefe56 2020-02-24 tracey only log messages but otherwise leaves every picked commit as-is.
2165 083957f4 2020-02-24 stsp option can only be used when starting a new histedit operation.
2166 083957f4 2020-02-24 stsp If this option is used, no other command-line arguments are allowed.
2168 e600f124 2021-03-21 stsp Show a list of past histedit operations, represented by references in the
2169 e600f124 2021-03-21 stsp .Dq refs/got/backup/histedit
2170 e600f124 2021-03-21 stsp reference namespace.
2172 e600f124 2021-03-21 stsp Display the author, date, and log message of each backed up commit,
2173 e600f124 2021-03-21 stsp the object ID of the corresponding post-histedit commit, and
2174 e600f124 2021-03-21 stsp the object ID of their common ancestor commit.
2175 e600f124 2021-03-21 stsp Given these object IDs,
2177 e600f124 2021-03-21 stsp .Cm got log
2178 e600f124 2021-03-21 stsp command with the
2182 e600f124 2021-03-21 stsp options can be used to examine the history of either version of the branch,
2184 e600f124 2021-03-21 stsp .Cm got branch
2185 e600f124 2021-03-21 stsp command with the
2187 e600f124 2021-03-21 stsp option can be used to create a new branch from a pre-histedit state if desired.
2190 e600f124 2021-03-21 stsp .Ar branch
2191 e600f124 2021-03-21 stsp is specified, only show commits which at some point in time represented this
2193 e600f124 2021-03-21 stsp Otherwise, list all backed up commits for any branches.
2195 e600f124 2021-03-21 stsp If this option is used,
2196 e600f124 2021-03-21 stsp .Cm got histedit
2197 e600f124 2021-03-21 stsp does not require a work tree.
2198 e600f124 2021-03-21 stsp None of the other options can be used together with
2201 643b85bc 2021-07-16 stsp Delete backups created by past histedit operations, represented by references
2203 643b85bc 2021-07-16 stsp .Dq refs/got/backup/histedit
2204 643b85bc 2021-07-16 stsp reference namespace.
2207 643b85bc 2021-07-16 stsp .Ar branch
2208 643b85bc 2021-07-16 stsp is specified, only delete backups which at some point in time represented
2209 643b85bc 2021-07-16 stsp this branch.
2210 643b85bc 2021-07-16 stsp Otherwise, delete all references found within
2211 643b85bc 2021-07-16 stsp .Dq refs/got/backup/histedit .
2213 643b85bc 2021-07-16 stsp Any commit, tree, tag, and blob objects belonging to deleted backups
2214 643b85bc 2021-07-16 stsp remain in the repository and may be removed separately with
2215 643b85bc 2021-07-16 stsp Git's garbage collector or
2216 643b85bc 2021-07-16 stsp .Cm gotadmin cleanup .
2218 643b85bc 2021-07-16 stsp If this option is used,
2219 643b85bc 2021-07-16 stsp .Cm got histedit
2220 643b85bc 2021-07-16 stsp does not require a work tree.
2221 643b85bc 2021-07-16 stsp None of the other options can be used together with
2225 2822a352 2019-10-15 stsp .It Cm integrate Ar branch
2226 d912d125 2021-11-04 thomas .Dl Pq alias: Cm ig
2227 2822a352 2019-10-15 stsp Integrate the specified
2228 2822a352 2019-10-15 stsp .Ar branch
2229 2822a352 2019-10-15 stsp into the work tree's current branch.
2230 2822a352 2019-10-15 stsp Files in the work tree are updated to match the contents on the integrated
2231 2822a352 2019-10-15 stsp .Ar branch ,
2232 2822a352 2019-10-15 stsp and the reference of the work tree's branch is changed to point at the
2233 2822a352 2019-10-15 stsp head commit of the integrated
2234 2822a352 2019-10-15 stsp .Ar branch .
2236 2822a352 2019-10-15 stsp Both branches can be considered equivalent after integration since they
2237 2822a352 2019-10-15 stsp will be pointing at the same commit.
2238 2822a352 2019-10-15 stsp Both branches remain available for future work, if desired.
2239 2822a352 2019-10-15 stsp In case the integrated
2240 2822a352 2019-10-15 stsp .Ar branch
2241 2822a352 2019-10-15 stsp is no longer needed it may be deleted with
2242 2822a352 2019-10-15 stsp .Cm got branch -d .
2244 2822a352 2019-10-15 stsp Show the status of each affected file, using the following status codes:
2245 2822a352 2019-10-15 stsp .Bl -column YXZ description
2246 2822a352 2019-10-15 stsp .It U Ta file was updated
2247 2822a352 2019-10-15 stsp .It D Ta file was deleted
2248 2822a352 2019-10-15 stsp .It A Ta new file was added
2249 2822a352 2019-10-15 stsp .It \(a~ Ta versioned file is obstructed by a non-regular file
2250 2822a352 2019-10-15 stsp .It ! Ta a missing versioned file was restored
2253 2822a352 2019-10-15 stsp .Cm got integrate
2254 2822a352 2019-10-15 stsp will refuse to run if certain preconditions are not met.
2255 2822a352 2019-10-15 stsp Most importantly, the
2256 2822a352 2019-10-15 stsp .Ar branch
2257 2822a352 2019-10-15 stsp must have been rebased onto the work tree's current branch with
2258 2822a352 2019-10-15 stsp .Cm got rebase
2259 2822a352 2019-10-15 stsp before it can be integrated, in order to linearize commit history and
2260 2822a352 2019-10-15 stsp resolve merge conflicts.
2261 4b06140e 2022-03-22 thomas If the work tree contains multiple base commits, it must first be updated
2262 2822a352 2019-10-15 stsp to a single base commit with
2263 2822a352 2019-10-15 stsp .Cm got update .
2264 2822a352 2019-10-15 stsp If changes have been staged with
2265 2822a352 2019-10-15 stsp .Cm got stage ,
2266 2822a352 2019-10-15 stsp these changes must first be committed with
2267 2822a352 2019-10-15 stsp .Cm got commit
2268 2822a352 2019-10-15 stsp or unstaged with
2269 2822a352 2019-10-15 stsp .Cm got unstage .
2270 2822a352 2019-10-15 stsp If the work tree contains local changes, these changes must first be
2271 2822a352 2019-10-15 stsp committed with
2272 2822a352 2019-10-15 stsp .Cm got commit
2273 2822a352 2019-10-15 stsp or reverted with
2274 2822a352 2019-10-15 stsp .Cm got revert .
2276 ba34626b 2021-09-27 thomas .It Cm merge Oo Fl a Oc Oo Fl c Oc Oo Fl n Oc Op Ar branch
2277 d912d125 2021-11-04 thomas .Dl Pq alias: Cm mg
2278 10604dce 2021-09-24 thomas Create a merge commit based on the current branch of the work tree and
2279 10604dce 2021-09-24 thomas the specified
2280 10604dce 2021-09-24 thomas .Ar branch .
2281 10604dce 2021-09-24 thomas If a linear project history is desired, then use of
2282 10604dce 2021-09-24 thomas .Cm got rebase
2283 10604dce 2021-09-24 thomas should be preferred over
2284 10604dce 2021-09-24 thomas .Cm got merge .
2285 10604dce 2021-09-24 thomas However, even strictly linear projects may require merge commits in order
2286 768705e3 2021-09-27 thomas to merge in new versions of third-party code stored on vendor branches
2287 768705e3 2021-09-27 thomas created with
2288 768705e3 2021-09-27 thomas .Cm got import .
2290 10604dce 2021-09-24 thomas Merge commits are commits based on multiple parent commits.
2291 10604dce 2021-09-24 thomas The tip commit of the work tree's current branch, which must be set with
2292 10604dce 2021-09-24 thomas .Cm got update -b
2293 10604dce 2021-09-24 thomas before starting the
2294 10604dce 2021-09-24 thomas .Cm merge
2295 10604dce 2021-09-24 thomas operation, will be used as the first parent.
2296 10604dce 2021-09-24 thomas The tip commit of the specified
2297 10604dce 2021-09-24 thomas .Ar branch
2298 10604dce 2021-09-24 thomas will be used as the second parent.
2300 768705e3 2021-09-27 thomas No ancestral relationship between the two branches is required.
2301 768705e3 2021-09-27 thomas If the two branches have already been merged previously, only new changes
2302 768705e3 2021-09-27 thomas will be merged.
2304 10604dce 2021-09-24 thomas It is not possible to create merge commits with more than two parents.
2305 10604dce 2021-09-24 thomas If more than one branch needs to be merged, then multiple merge commits
2306 10604dce 2021-09-24 thomas with two parents each can be created in sequence.
2308 10604dce 2021-09-24 thomas While merging changes found on the
2309 10604dce 2021-09-24 thomas .Ar branch
2310 10604dce 2021-09-24 thomas into the work tree, show the status of each affected file,
2311 10604dce 2021-09-24 thomas using the following status codes:
2312 10604dce 2021-09-24 thomas .Bl -column YXZ description
2313 10604dce 2021-09-24 thomas .It G Ta file was merged
2314 10604dce 2021-09-24 thomas .It C Ta file was merged and conflicts occurred during merge
2315 10604dce 2021-09-24 thomas .It ! Ta changes destined for a missing file were not merged
2316 10604dce 2021-09-24 thomas .It D Ta file was deleted
2317 df3d7c3e 2021-09-24 thomas .It d Ta file's deletion was prevented by local modifications
2318 10604dce 2021-09-24 thomas .It A Ta new file was added
2319 10604dce 2021-09-24 thomas .It \(a~ Ta changes destined for a non-regular file were not merged
2320 10604dce 2021-09-24 thomas .It ? Ta changes destined for an unversioned file were not merged
2323 10604dce 2021-09-24 thomas If merge conflicts occur, the merge operation is interrupted and conflicts
2324 10604dce 2021-09-24 thomas must be resolved before the merge operation can continue.
2325 8cf2970b 2021-09-28 thomas If any files with destined changes are found to be missing or unversioned,
2326 8cf2970b 2021-09-28 thomas or if files could not be deleted due to differences in deleted content,
2327 10604dce 2021-09-24 thomas the merge operation will be interrupted to prevent potentially incomplete
2328 10604dce 2021-09-24 thomas changes from being committed to the repository without user intervention.
2329 10604dce 2021-09-24 thomas The work tree may be modified as desired and the merge can be continued
2330 10604dce 2021-09-24 thomas once the changes present in the work tree are considered complete.
2331 10604dce 2021-09-24 thomas Alternatively, the merge operation may be aborted which will leave
2332 10604dce 2021-09-24 thomas the work tree's current branch unmodified.
2334 10604dce 2021-09-24 thomas If a merge conflict is resolved in a way which renders all merged
2335 10604dce 2021-09-24 thomas changes into no-op changes, the merge operation cannot continue
2336 10604dce 2021-09-24 thomas and must be aborted.
2338 10604dce 2021-09-24 thomas .Cm got merge
2339 10604dce 2021-09-24 thomas will refuse to run if certain preconditions are not met.
2340 10604dce 2021-09-24 thomas If history of the
2341 10604dce 2021-09-24 thomas .Ar branch
2342 10604dce 2021-09-24 thomas is based on the work tree's current branch, then no merge commit can
2343 10604dce 2021-09-24 thomas be created and
2344 10604dce 2021-09-24 thomas .Cm got integrate
2345 10604dce 2021-09-24 thomas may be used to integrate the
2346 10604dce 2021-09-24 thomas .Ar branch
2347 10604dce 2021-09-24 thomas instead.
2348 10604dce 2021-09-24 thomas If the work tree is not yet fully updated to the tip commit of its
2349 10604dce 2021-09-24 thomas branch, then the work tree must first be updated with
2350 10604dce 2021-09-24 thomas .Cm got update .
2351 4b06140e 2022-03-22 thomas If the work tree contains multiple base commits, it must first be updated
2352 10604dce 2021-09-24 thomas to a single base commit with
2353 10604dce 2021-09-24 thomas .Cm got update .
2354 10604dce 2021-09-24 thomas If changes have been staged with
2355 10604dce 2021-09-24 thomas .Cm got stage ,
2356 10604dce 2021-09-24 thomas these changes must first be committed with
2357 10604dce 2021-09-24 thomas .Cm got commit
2358 10604dce 2021-09-24 thomas or unstaged with
2359 10604dce 2021-09-24 thomas .Cm got unstage .
2360 10604dce 2021-09-24 thomas If the work tree contains local changes, these changes must first be
2361 10604dce 2021-09-24 thomas committed with
2362 10604dce 2021-09-24 thomas .Cm got commit
2363 10604dce 2021-09-24 thomas or reverted with
2364 10604dce 2021-09-24 thomas .Cm got revert .
2366 10604dce 2021-09-24 thomas .Ar branch
2367 10604dce 2021-09-24 thomas contains changes to files outside of the work tree's path prefix,
2368 10604dce 2021-09-24 thomas the work tree cannot be used to merge this branch.
2371 10604dce 2021-09-24 thomas .Cm got update ,
2372 10604dce 2021-09-24 thomas .Cm got commit ,
2373 10604dce 2021-09-24 thomas .Cm got rebase ,
2374 ac93b2c5 2021-10-08 thomas .Cm got histedit ,
2375 10604dce 2021-09-24 thomas .Cm got integrate ,
2377 10604dce 2021-09-24 thomas .Cm got stage
2378 10604dce 2021-09-24 thomas commands will refuse to run while a merge operation is in progress.
2379 10604dce 2021-09-24 thomas Other commands which manipulate the work tree may be used for
2380 10604dce 2021-09-24 thomas conflict resolution purposes.
2382 10604dce 2021-09-24 thomas The options for
2383 10604dce 2021-09-24 thomas .Cm got merge
2384 10604dce 2021-09-24 thomas are as follows:
2385 10604dce 2021-09-24 thomas .Bl -tag -width Ds
2386 10604dce 2021-09-24 thomas .It Fl a
2387 10604dce 2021-09-24 thomas Abort an interrupted merge operation.
2388 10604dce 2021-09-24 thomas If this option is used, no other command-line arguments are allowed.
2389 10604dce 2021-09-24 thomas .It Fl c
2390 10604dce 2021-09-24 thomas Continue an interrupted merge operation.
2391 10604dce 2021-09-24 thomas If this option is used, no other command-line arguments are allowed.
2392 ba34626b 2021-09-27 thomas .It Fl n
2393 ba34626b 2021-09-27 thomas Merge changes into the work tree as usual but do not create a merge
2394 ba34626b 2021-09-27 thomas commit immediately.
2395 ba34626b 2021-09-27 thomas The merge result can be adjusted as desired before a merge commit is
2396 ba34626b 2021-09-27 thomas created with
2397 ba34626b 2021-09-27 thomas .Cm got merge -c .
2398 ba34626b 2021-09-27 thomas Alternatively, the merge may be aborted with
2399 ba34626b 2021-09-27 thomas .Cm got merge -a .
2402 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 ...
2403 d912d125 2021-11-04 thomas .Dl Pq alias: Cm sg
2404 2db2652d 2019-08-07 stsp Stage local changes for inclusion in the next commit.
2407 2db2652d 2019-08-07 stsp is specified, stage all changes in the work tree.
2408 2db2652d 2019-08-07 stsp Otherwise, stage changes at or within the specified paths.
2409 4ed9f614 2019-08-04 stsp Paths may be staged if they are added, modified, or deleted according to
2410 4ed9f614 2019-08-04 stsp .Cm got status .
2412 9d8b19a4 2019-08-04 stsp Show the status of each affected file, using the following status codes:
2413 9d8b19a4 2019-08-04 stsp .Bl -column YXZ description
2414 9d8b19a4 2019-08-04 stsp .It A Ta file addition has been staged
2415 9d8b19a4 2019-08-04 stsp .It M Ta file modification has been staged
2416 9d8b19a4 2019-08-04 stsp .It D Ta file deletion has been staged
2419 9d8b19a4 2019-08-04 stsp Staged file contents are saved in newly created blob objects in the repository.
2420 52c8d4ac 2019-08-04 stsp These blobs will be referred to by tree objects once staged changes have been
2421 9d8b19a4 2019-08-04 stsp committed.
2423 890ea719 2019-08-04 stsp Staged changes affect the behaviour of
2424 4ed9f614 2019-08-04 stsp .Cm got commit ,
2425 4ed9f614 2019-08-04 stsp .Cm got status ,
2427 4ed9f614 2019-08-04 stsp .Cm got diff .
2428 4ed9f614 2019-08-04 stsp While paths with staged changes exist, the
2429 4ed9f614 2019-08-04 stsp .Cm got commit
2430 4ed9f614 2019-08-04 stsp command will refuse to commit any paths which do not have staged changes.
2431 4ed9f614 2019-08-04 stsp Local changes created on top of staged changes can only be committed if
2432 4ed9f614 2019-08-04 stsp the path is staged again, or if the staged changes are committed first.
2434 4ed9f614 2019-08-04 stsp .Cm got status
2435 4ed9f614 2019-08-04 stsp command will show both local changes and staged changes.
2437 4ed9f614 2019-08-04 stsp .Cm got diff
2438 ecf14362 2019-08-04 stsp command is able to display local changes relative to staged changes,
2439 ecf14362 2019-08-04 stsp and to display staged changes relative to the repository.
2441 4ed9f614 2019-08-04 stsp .Cm got revert
2442 4ed9f614 2019-08-04 stsp command cannot revert staged changes but may be used to revert
2443 4f2494e6 2019-08-08 stsp local changes created on top of staged changes.
2445 4ed9f614 2019-08-04 stsp The options for
2446 4ed9f614 2019-08-04 stsp .Cm got stage
2447 4ed9f614 2019-08-04 stsp are as follows:
2448 4ed9f614 2019-08-04 stsp .Bl -tag -width Ds
2450 4ed9f614 2019-08-04 stsp Instead of staging new changes, list paths which are already staged,
2451 9d8b19a4 2019-08-04 stsp along with the IDs of staged blob objects and stage status codes.
2452 4b06140e 2022-03-22 thomas If paths were provided on the command line, show the staged paths
2453 1dd86744 2019-08-12 anthony among the specified paths.
2454 1dd86744 2019-08-12 anthony Otherwise, show all staged paths.
2456 dc424a06 2019-08-07 stsp Instead of staging the entire content of a changed file, interactively
2457 dc424a06 2019-08-07 stsp select or reject changes for staging based on
2459 6d23ec10 2019-08-08 stsp (stage change),
2461 6d23ec10 2019-08-08 stsp (reject change), and
2463 6d23ec10 2019-08-08 stsp (quit staging this file) responses.
2464 dc424a06 2019-08-07 stsp If a file is in modified status, individual patches derived from the
2465 dc424a06 2019-08-07 stsp modified file content can be staged.
2466 6d23ec10 2019-08-08 stsp Files in added or deleted status may only be staged or rejected in
2467 6d23ec10 2019-08-08 stsp their entirety.
2468 3a070a2b 2019-08-07 stsp .It Fl F Ar response-script
2471 3a070a2b 2019-08-07 stsp option, read
2476 0e2f5884 2019-08-07 stsp responses line-by-line from the specified
2477 0e2f5884 2019-08-07 stsp .Ar response-script
2478 0e2f5884 2019-08-07 stsp file instead of prompting interactively.
2480 af358f55 2020-07-23 stsp Allow staging of symbolic links which point outside of the path space
2481 af358f55 2020-07-23 stsp that is under version control.
2482 af358f55 2020-07-23 stsp By default,
2483 af358f55 2020-07-23 stsp .Cm got stage
2484 af358f55 2020-07-23 stsp will reject such symbolic links due to safety concerns.
2485 35213c7c 2020-07-23 stsp As a precaution,
2487 af358f55 2020-07-23 stsp may decide to represent such a symbolic link as a regular file which contains
2488 af358f55 2020-07-23 stsp the link's target path, rather than creating an actual symbolic link which
2489 af358f55 2020-07-23 stsp points outside of the work tree.
2490 af358f55 2020-07-23 stsp Use of this option is discouraged because external mechanisms such as
2491 af358f55 2020-07-23 stsp .Dq make obj
2492 af358f55 2020-07-23 stsp are better suited for managing symbolic links to paths not under
2493 af358f55 2020-07-23 stsp version control.
2496 4ed9f614 2019-08-04 stsp .Cm got stage
2497 4ed9f614 2019-08-04 stsp will refuse to run if certain preconditions are not met.
2498 4ed9f614 2019-08-04 stsp If a file contains merge conflicts, these conflicts must be resolved first.
2499 4ed9f614 2019-08-04 stsp If a file is found to be out of date relative to the head commit on the
2500 4ed9f614 2019-08-04 stsp work tree's current branch, the file must be updated with
2501 4ed9f614 2019-08-04 stsp .Cm got update
2502 4ed9f614 2019-08-04 stsp before it can be staged (however, this does not prevent the file from
2503 4ed9f614 2019-08-04 stsp becoming out-of-date at some point after having been staged).
2506 4ed9f614 2019-08-04 stsp .Cm got update ,
2507 4ed9f614 2019-08-04 stsp .Cm got rebase ,
2509 4ed9f614 2019-08-04 stsp .Cm got histedit
2510 4ed9f614 2019-08-04 stsp commands will refuse to run while staged changes exist.
2511 4ed9f614 2019-08-04 stsp If staged changes cannot be committed because a staged path
2512 4ed9f614 2019-08-04 stsp is out of date, the path must be unstaged with
2513 4ed9f614 2019-08-04 stsp .Cm got unstage
2514 4ed9f614 2019-08-04 stsp before it can be updated with
2515 4ed9f614 2019-08-04 stsp .Cm got update ,
2516 4ed9f614 2019-08-04 stsp and may then be staged again if necessary.
2518 dfc23429 2019-08-11 stsp .It Cm unstage Oo Fl p Oc Oo Fl F Ar response-script Oc Op Ar path ...
2519 d912d125 2021-11-04 thomas .Dl Pq alias: Cm ug
2520 4ed9f614 2019-08-04 stsp Merge staged changes back into the work tree and put affected paths
2521 4ed9f614 2019-08-04 stsp back into non-staged status.
2524 4ed9f614 2019-08-04 stsp is specified, unstage all staged changes across the entire work tree.
2525 2db2652d 2019-08-07 stsp Otherwise, unstage changes at or within the specified paths.
2527 4ed9f614 2019-08-04 stsp Show the status of each affected file, using the following status codes:
2528 4ed9f614 2019-08-04 stsp .Bl -column YXZ description
2529 4ed9f614 2019-08-04 stsp .It G Ta file was unstaged
2530 4ed9f614 2019-08-04 stsp .It C Ta file was unstaged and conflicts occurred during merge
2531 4ed9f614 2019-08-04 stsp .It ! Ta changes destined for a missing file were not merged
2532 4ed9f614 2019-08-04 stsp .It D Ta file was staged as deleted and still is deleted
2533 df3d7c3e 2021-09-24 thomas .It d Ta file's deletion was prevented by local modifications
2534 1dd86744 2019-08-12 anthony .It \(a~ Ta changes destined for a non-regular file were not merged
2537 2e1f37b0 2019-08-08 stsp The options for
2538 2e1f37b0 2019-08-08 stsp .Cm got unstage
2539 2e1f37b0 2019-08-08 stsp are as follows:
2540 2e1f37b0 2019-08-08 stsp .Bl -tag -width Ds
2542 2e1f37b0 2019-08-08 stsp Instead of unstaging the entire content of a changed file, interactively
2543 2e1f37b0 2019-08-08 stsp select or reject changes for unstaging based on
2545 2e1f37b0 2019-08-08 stsp (unstage change),
2547 2e1f37b0 2019-08-08 stsp (keep change staged), and
2549 2e1f37b0 2019-08-08 stsp (quit unstaging this file) responses.
2550 2e1f37b0 2019-08-08 stsp If a file is staged in modified status, individual patches derived from the
2551 2e1f37b0 2019-08-08 stsp staged file content can be unstaged.
2552 2e1f37b0 2019-08-08 stsp Files staged in added or deleted status may only be unstaged in their entirety.
2553 2e1f37b0 2019-08-08 stsp .It Fl F Ar response-script
2556 2e1f37b0 2019-08-08 stsp option, read
2561 2e1f37b0 2019-08-08 stsp responses line-by-line from the specified
2562 2e1f37b0 2019-08-08 stsp .Ar response-script
2563 2e1f37b0 2019-08-08 stsp file instead of prompting interactively.
2565 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 ...
2566 896e9b6f 2019-08-26 stsp Parse and print contents of objects to standard output in a line-based
2567 896e9b6f 2019-08-26 stsp text format.
2568 896e9b6f 2019-08-26 stsp Content of commit, tree, and tag objects is printed in a way similar
2569 896e9b6f 2019-08-26 stsp to the actual content stored in such objects.
2570 896e9b6f 2019-08-26 stsp Blob object contents are printed as they would appear in files on disk.
2572 896e9b6f 2019-08-26 stsp Attempt to interpret each argument as a reference, a tag name, or
2573 896e9b6f 2019-08-26 stsp an object ID SHA1 hash.
2574 01073a5d 2019-08-22 stsp References will be resolved to an object ID.
2575 01073a5d 2019-08-22 stsp Tag names will resolved to a tag object.
2576 01073a5d 2019-08-22 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
2577 01073a5d 2019-08-22 stsp automatically, provided the abbreviation is unique.
2579 896e9b6f 2019-08-26 stsp If none of the above interpretations produce a valid result, or if the
2581 896e9b6f 2019-08-26 stsp option is used, attempt to interpret the argument as a path which will
2582 896e9b6f 2019-08-26 stsp be resolved to the ID of an object found at this path in the repository.
2584 01073a5d 2019-08-22 stsp The options for
2585 01073a5d 2019-08-22 stsp .Cm got cat
2586 01073a5d 2019-08-22 stsp are as follows:
2587 01073a5d 2019-08-22 stsp .Bl -tag -width Ds
2588 896e9b6f 2019-08-26 stsp .It Fl c Ar commit
2589 896e9b6f 2019-08-26 stsp Look up paths in the specified
2590 896e9b6f 2019-08-26 stsp .Ar commit .
2591 896e9b6f 2019-08-26 stsp If this option is not used, paths are looked up in the commit resolved
2592 896e9b6f 2019-08-26 stsp via the repository's HEAD reference.
2593 896e9b6f 2019-08-26 stsp The expected argument is a commit ID SHA1 hash or an existing reference
2594 896e9b6f 2019-08-26 stsp or tag name which will be resolved to a commit ID.
2595 896e9b6f 2019-08-26 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
2596 896e9b6f 2019-08-26 stsp automatically, provided the abbreviation is unique.
2597 01073a5d 2019-08-22 stsp .It Fl r Ar repository-path
2598 01073a5d 2019-08-22 stsp Use the repository at the specified path.
2599 01073a5d 2019-08-22 stsp If not specified, assume the repository is located at or above the current
2600 01073a5d 2019-08-22 stsp working directory.
2601 01073a5d 2019-08-22 stsp If this directory is a
2603 01073a5d 2019-08-22 stsp work tree, use the repository path associated with this work tree.
2605 896e9b6f 2019-08-26 stsp Interpret all arguments as paths only.
2606 896e9b6f 2019-08-26 stsp This option can be used to resolve ambiguity in cases where paths
2607 896e9b6f 2019-08-26 stsp look like tag names, reference names, or object IDs.
2609 b2118c49 2020-07-28 stsp .It Cm info Op Ar path ...
2610 b2118c49 2020-07-28 stsp Display meta-data stored in a work tree.
2612 b2118c49 2020-07-28 stsp .Xr got-worktree 5
2613 b2118c49 2020-07-28 stsp for details.
2615 b2118c49 2020-07-28 stsp The work tree to use is resolved implicitly by walking upwards from the
2616 b2118c49 2020-07-28 stsp current working directory.
2618 b2118c49 2020-07-28 stsp If one or more
2620 b2118c49 2020-07-28 stsp arguments are specified, show additional per-file information for tracked
2621 b2118c49 2020-07-28 stsp files located at or within these paths.
2624 b2118c49 2020-07-28 stsp argument corresponds to the work tree's root directory, display information
2625 b2118c49 2020-07-28 stsp for all tracked files.
2627 74416c47 2019-05-09 stsp .Sh ENVIRONMENT
2628 74416c47 2019-05-09 stsp .Bl -tag -width GOT_AUTHOR
2629 74416c47 2019-05-09 stsp .It Ev GOT_AUTHOR
2630 74416c47 2019-05-09 stsp The author's name and email address for
2631 21a44f98 2019-07-15 stsp .Cm got commit
2633 21a44f98 2019-07-15 stsp .Cm got import ,
2634 74416c47 2019-05-09 stsp for example:
2635 aba9c984 2019-09-08 stsp .Dq An Flan Hacker Aq Mt flan_hacker@openbsd.org .
2638 84792843 2019-08-09 stsp may fail to parse commits without an email address in author data,
2640 84792843 2019-08-09 stsp attempts to reject
2641 0e444aba 2019-08-08 stsp .Ev GOT_AUTHOR
2642 84792843 2019-08-09 stsp environment variables with a missing email address.
2644 93a300b2 2021-08-26 stsp .Ev GOT_AUTHOR will be overridden by configuration settings in
2645 50b0790e 2020-09-11 stsp .Xr got.conf 5
2646 50b0790e 2020-09-11 stsp or by Git's
2647 aba9c984 2019-09-08 stsp .Dv user.name
2649 709ae9eb 2019-09-08 stsp .Dv user.email
2650 709ae9eb 2019-09-08 stsp configuration settings in the repository's
2651 aba9c984 2019-09-08 stsp .Pa .git/config
2654 c9956ddf 2019-09-08 stsp .Dv user.name
2656 c9956ddf 2019-09-08 stsp .Dv user.email
2657 c9956ddf 2019-09-08 stsp configuration settings contained in Git's global
2658 c9956ddf 2019-09-08 stsp .Pa ~/.gitconfig
2659 257add31 2020-09-09 stsp configuration file will only be used if neither
2660 257add31 2020-09-09 stsp .Xr got.conf 5
2662 c9956ddf 2019-09-08 stsp .Ev GOT_AUTHOR
2663 257add31 2020-09-09 stsp environment variable provide author information.
2664 1dd86744 2019-08-12 anthony .It Ev VISUAL , EDITOR
2665 23594da9 2019-05-13 stsp The editor spawned by
2666 8e7bd50a 2019-08-22 stsp .Cm got commit ,
2667 46215d2a 2020-09-11 stsp .Cm got histedit ,
2668 8e7bd50a 2019-08-22 stsp .Cm got import ,
2670 8e7bd50a 2019-08-22 stsp .Cm got tag .
2671 5b735925 2020-09-15 stsp If not set, the
2673 5b735925 2020-09-15 stsp text editor will be spawned in order to give
2675 5b735925 2020-09-15 stsp the attention it deserves.
2676 b1ebc001 2019-08-13 stsp .It Ev GOT_LOG_DEFAULT_LIMIT
2677 b1ebc001 2019-08-13 stsp The default limit on the number of commits traversed by
2678 b1ebc001 2019-08-13 stsp .Cm got log .
2679 b1ebc001 2019-08-13 stsp If set to zero, the limit is unbounded.
2680 b1ebc001 2019-08-13 stsp This variable will be silently ignored if it is set to a non-numeric value.
2683 257add31 2020-09-09 stsp .Bl -tag -width packed-refs -compact
2684 257add31 2020-09-09 stsp .It Pa got.conf
2685 257add31 2020-09-09 stsp Repository-wide configuration settings for
2687 50b0790e 2020-09-11 stsp If present, a
2688 50b0790e 2020-09-11 stsp .Xr got.conf 5
2689 50b0790e 2020-09-11 stsp configuration file located in the root directory of a Git repository
2690 50b0790e 2020-09-11 stsp supersedes any relevant settings in Git's
2691 257add31 2020-09-09 stsp .Pa config
2694 50b0790e 2020-09-11 stsp .It Pa .got/got.conf
2695 50b0790e 2020-09-11 stsp Worktree-specific configuration settings for
2697 50b0790e 2020-09-11 stsp If present, a
2698 1795b260 2021-04-02 kn .Xr got.conf 5
2699 50b0790e 2020-09-11 stsp configuration file in the
2701 50b0790e 2020-09-11 stsp meta-data directory of a work tree supersedes any relevant settings in
2702 50b0790e 2020-09-11 stsp the repository's
2703 50b0790e 2020-09-11 stsp .Xr got.conf 5
2704 50b0790e 2020-09-11 stsp configuration file and Git's
2705 50b0790e 2020-09-11 stsp .Pa config
2708 5c860e29 2018-03-12 stsp .Sh EXIT STATUS
2709 5c860e29 2018-03-12 stsp .Ex -std got
2710 97925469 2018-03-17 stsp .Sh EXAMPLES
2711 43e4eb1b 2021-08-29 stsp Enable tab-completion of
2713 43e4eb1b 2021-08-29 stsp command names in
2714 43e4eb1b 2021-08-29 stsp .Xr ksh 1 :
2716 e1d27370 2021-09-01 stsp .Dl $ set -A complete_got_1 -- $(got -h 2>&1 | sed -n s/commands://p)
2718 fa6e0e48 2019-05-23 stsp Clone an existing Git repository for use with
2721 fd039d72 2020-03-18 stsp .Dl $ cd /var/git/
2722 fd039d72 2020-03-18 stsp .Dl $ got clone ssh://git@github.com/openbsd/src.git
2724 fd039d72 2020-03-18 stsp Use of HTTP URLs currently requires
2725 fa6e0e48 2019-05-23 stsp .Xr git 1 :
2727 fa6e0e48 2019-05-23 stsp .Dl $ cd /var/git/
2728 fa6e0e48 2019-05-23 stsp .Dl $ git clone --bare https://github.com/openbsd/src.git
2730 3ce1b845 2019-07-15 stsp Alternatively, for quick and dirty local testing of
2732 3ce1b845 2019-07-15 stsp a new Git repository could be created and populated with files,
2733 3ce1b845 2019-07-15 stsp e.g. from a temporary CVS checkout located at
2734 3ce1b845 2019-07-15 stsp .Pa /tmp/src :
2736 3ce1b845 2019-07-15 stsp .Dl $ got init /var/git/src.git
2737 2930ef13 2019-07-15 stsp .Dl $ got import -r /var/git/src.git -I CVS -I obj /tmp/src
2739 3ce1b845 2019-07-15 stsp Check out a work tree from the Git repository to /usr/src:
2741 fa6e0e48 2019-05-23 stsp .Dl $ got checkout /var/git/src.git /usr/src
2743 e70c17ce 2019-05-22 stsp View local changes in a work tree directory:
2745 e70c17ce 2019-05-22 stsp .Dl $ got diff | less
2747 081470ac 2020-08-13 stsp In a work tree, display files in a potentially problematic state:
2749 081470ac 2020-08-13 stsp .Dl $ got status -s 'C!~?'
2751 33aa809d 2019-08-08 stsp Interactively revert selected local changes in a work tree directory:
2753 33aa809d 2019-08-08 stsp .Dl $ got revert -p -R\ .
2755 e70c17ce 2019-05-22 stsp In a work tree or a git repository directory, list all branch references:
2757 4e759de4 2019-06-26 stsp .Dl $ got branch -l
2759 fa6e0e48 2019-05-23 stsp In a work tree or a git repository directory, create a new branch called
2760 e70c17ce 2019-05-22 stsp .Dq unified-buffer-cache
2761 d83d9d5c 2019-05-13 stsp which is forked off the
2762 d83d9d5c 2019-05-13 stsp .Dq master
2765 7b4f1fcb 2021-01-27 stsp .Dl $ got branch -c master unified-buffer-cache
2767 e70c17ce 2019-05-22 stsp Switch an existing work tree to the branch
2768 e70c17ce 2019-05-22 stsp .Dq unified-buffer-cache .
2769 e70c17ce 2019-05-22 stsp Local changes in the work tree will be preserved and merged if necessary:
2771 e70c17ce 2019-05-22 stsp .Dl $ got update -b unified-buffer-cache
2773 fa6e0e48 2019-05-23 stsp Create a new commit from local changes in a work tree directory.
2774 fa6e0e48 2019-05-23 stsp This new commit will become the head commit of the work tree's current branch:
2776 fa6e0e48 2019-05-23 stsp .Dl $ got commit
2778 fa6e0e48 2019-05-23 stsp In a work tree or a git repository directory, view changes committed in
2779 fa6e0e48 2019-05-23 stsp the 3 most recent commits to the work tree's branch, or the branch resolved
2780 fa6e0e48 2019-05-23 stsp via the repository's HEAD reference, respectively:
2782 48c8c60d 2020-01-27 stsp .Dl $ got log -p -l 3
2784 3d0ac559 2020-04-18 stsp As above, but display changes in the order in which
2785 04e9dcf3 2020-04-18 stsp .Xr patch 1
2786 04e9dcf3 2020-04-18 stsp could apply them in sequence:
2788 04e9dcf3 2020-04-18 stsp .Dl $ got log -p -l 3 -R
2790 5b666081 2020-02-24 stsp In a work tree or a git repository directory, log the history of a subdirectory:
2792 5b666081 2020-02-24 stsp .Dl $ got log sys/uvm
2794 5b666081 2020-02-24 stsp While operating inside a work tree, paths are specified relative to the current
2795 5b666081 2020-02-24 stsp working directory, so this command will log the subdirectory
2796 5b666081 2020-02-24 stsp .Pa sys/uvm :
2798 cf07f22b 2020-07-25 stsp .Dl $ cd sys/uvm && got log\ .
2800 5b666081 2020-02-24 stsp And this command has the same effect:
2802 5b666081 2020-02-24 stsp .Dl $ cd sys/dev/usb && got log ../../uvm
2804 b2118c49 2020-07-28 stsp And this command displays work tree meta-data about all tracked files:
2806 b2118c49 2020-07-28 stsp .Dl $ cd /usr/src
2807 b2118c49 2020-07-28 stsp .Dl $ got info\ . | less
2809 e70c17ce 2019-05-22 stsp Add new files and remove obsolete files in a work tree directory:
2811 fa6e0e48 2019-05-23 stsp .Dl $ got add sys/uvm/uvm_ubc.c
2812 86d25a1b 2019-07-11 stsp .Dl $ got remove sys/uvm/uvm_vnode.c
2814 e70c17ce 2019-05-22 stsp Create a new commit from local changes in a work tree directory
2815 e70c17ce 2019-05-22 stsp with a pre-defined log message.
2817 e70c17ce 2019-05-22 stsp .Dl $ got commit -m 'unify the buffer cache'
2819 bcbc2272 2020-05-20 stsp Alternatively, create a new commit from local changes in a work tree
2820 bcbc2272 2020-05-20 stsp directory with a log message that has been prepared in the file
2821 1795b260 2021-04-02 kn .Pa /tmp/msg :
2823 28cf319f 2021-01-28 stsp .Dl $ got commit -F /tmp/msg
2825 95fc3404 2019-07-15 stsp Update any work tree checked out from the
2826 95fc3404 2019-07-15 stsp .Dq unified-buffer-cache
2827 95fc3404 2019-07-15 stsp branch to the latest commit on this branch:
2829 95fc3404 2019-07-15 stsp .Dl $ got update
2831 c991308a 2019-07-15 stsp Roll file content on the unified-buffer-cache branch back by one commit,
2832 c991308a 2019-07-15 stsp and then fetch the rolled-back change into the work tree as a local change
2833 ac90e726 2019-07-15 stsp to be amended and perhaps committed again:
2835 ac90e726 2019-07-15 stsp .Dl $ got backout unified-buffer-cache
2836 ac90e726 2019-07-15 stsp .Dl $ got commit -m 'roll back previous'
2837 59d52b88 2019-07-15 stsp .Dl $ # now back out the previous backout :-)
2838 ac90e726 2019-07-15 stsp .Dl $ got backout unified-buffer-cache
2840 a099809f 2021-08-27 stsp Fetch new changes on the remote repository's
2841 a099809f 2021-08-27 stsp .Dq master
2842 a099809f 2021-08-27 stsp branch, making them visible on the local repository's
2843 469dd726 2020-03-20 stsp .Dq origin/master
2846 469dd726 2020-03-20 stsp .Dl $ cd /usr/src
2847 469dd726 2020-03-20 stsp .Dl $ got fetch
2849 469dd726 2020-03-20 stsp In a repository created with a HTTP URL and
2850 469dd726 2020-03-20 stsp .Cm git clone --bare
2852 469dd726 2020-03-20 stsp .Xr git-fetch 1
2853 469dd726 2020-03-20 stsp command must be used instead:
2855 fa6e0e48 2019-05-23 stsp .Dl $ cd /var/git/src.git
2856 469dd726 2020-03-20 stsp .Dl $ git fetch origin master:refs/remotes/origin/master
2858 469dd726 2020-03-20 stsp Rebase the local
2859 469dd726 2020-03-20 stsp .Dq master
2860 469dd726 2020-03-20 stsp branch to merge the new changes that are now visible on the
2861 469dd726 2020-03-20 stsp .Dq origin/master
2864 469dd726 2020-03-20 stsp .Dl $ cd /usr/src
2865 469dd726 2020-03-20 stsp .Dl $ got update -b origin/master
2866 469dd726 2020-03-20 stsp .Dl $ got rebase master
2868 fa6e0e48 2019-05-23 stsp Rebase the
2869 fa6e0e48 2019-05-23 stsp .Dq unified-buffer-cache
2870 fa6e0e48 2019-05-23 stsp branch on top of the new head commit of the
2871 fa6e0e48 2019-05-23 stsp .Dq master
2874 818c7501 2019-07-11 stsp .Dl $ got update -b master
2875 818c7501 2019-07-11 stsp .Dl $ got rebase unified-buffer-cache
2877 7d7ffedb 2019-07-14 stsp Create a patch from all changes on the unified-buffer-cache branch.
2878 1dd86744 2019-08-12 anthony The patch can be mailed out for review and applied to
2879 1dd86744 2019-08-12 anthony .Ox Ns 's
2880 1dd86744 2019-08-12 anthony CVS tree:
2882 7d7ffedb 2019-07-14 stsp .Dl $ got diff master unified-buffer-cache > /tmp/ubc.diff
2884 0ebf8283 2019-07-24 stsp Edit the entire commit history of the
2885 0ebf8283 2019-07-24 stsp .Dq unified-buffer-cache
2888 0ebf8283 2019-07-24 stsp .Dl $ got update -b unified-buffer-cache
2889 0ebf8283 2019-07-24 stsp .Dl $ got update -c master
2890 0ebf8283 2019-07-24 stsp .Dl $ got histedit
2892 ff2cf171 2019-07-28 stsp Before working against existing branches in a repository cloned with
2893 469dd726 2020-03-20 stsp .Cm git clone --bare
2894 7848a0e1 2020-03-19 stsp instead of
2895 7848a0e1 2020-03-19 stsp .Cm got clone ,
2897 ff2cf171 2019-07-28 stsp .Dq refspec
2898 ff2cf171 2019-07-28 stsp must be configured to map all references in the remote repository
2900 ff2cf171 2019-07-28 stsp .Dq refs/remotes
2901 ff2cf171 2019-07-28 stsp namespace of the local repository.
2902 1795b260 2021-04-02 kn This can be achieved by setting Git's
2903 ff2cf171 2019-07-28 stsp .Pa remote.origin.fetch
2904 ff2cf171 2019-07-28 stsp configuration variable to the value
2905 ff2cf171 2019-07-28 stsp .Dq +refs/heads/*:refs/remotes/origin/*
2907 ff2cf171 2019-07-28 stsp .Cm git config
2910 ff2cf171 2019-07-28 stsp .Dl $ cd /var/git/repo
2911 ff2cf171 2019-07-28 stsp .Dl $ git config remote.origin.fetch '+refs/heads/*:refs/remotes/origin/*'
2913 469dd726 2020-03-20 stsp Additionally, the
2914 469dd726 2020-03-20 stsp .Dq mirror
2915 469dd726 2020-03-20 stsp option must be disabled:
2917 469dd726 2020-03-20 stsp .Dl $ cd /var/git/repo
2918 469dd726 2020-03-20 stsp .Dl $ git config remote.origin.mirror false
2920 ff2cf171 2019-07-28 stsp Alternatively, the following
2921 469dd726 2020-03-20 stsp .Xr git-fetch 1
2922 ff2cf171 2019-07-28 stsp configuration item can be added manually to the Git repository's
2923 ff2cf171 2019-07-28 stsp .Pa config
2926 91c82228 2021-04-18 stsp .Dl [remote \&"origin\&"]
2927 ff2cf171 2019-07-28 stsp .Dl url = ...
2928 ff2cf171 2019-07-28 stsp .Dl fetch = +refs/heads/*:refs/remotes/origin/*
2929 469dd726 2020-03-20 stsp .Dl mirror = false
2931 fe307c9b 2019-07-28 stsp This configuration leaves the local repository's
2932 ff2cf171 2019-07-28 stsp .Dq refs/heads
2933 ff2cf171 2019-07-28 stsp namespace free for use by local branches checked out with
2934 ff2cf171 2019-07-28 stsp .Cm got checkout
2935 ff2cf171 2019-07-28 stsp and, if needed, created with
2936 ff2cf171 2019-07-28 stsp .Cm got branch .
2937 ff2cf171 2019-07-28 stsp Branches in the
2938 a099809f 2021-08-27 stsp .Dq refs/remotes/origin
2939 469dd726 2020-03-20 stsp namespace can now be updated with incoming changes from the remote
2940 ff2cf171 2019-07-28 stsp repository with
2941 469dd726 2020-03-20 stsp .Cm got fetch
2943 469dd726 2020-03-20 stsp .Xr git-fetch 1
2944 a099809f 2021-08-27 stsp without extra command line arguments.
2945 a099809f 2021-08-27 stsp Newly fetched changes can be examined with
2946 a099809f 2021-08-27 stsp .Cm got log .
2948 a099809f 2021-08-27 stsp Display changes on the remote repository's version of the
2949 ff2cf171 2019-07-28 stsp .Dq master
2950 a099809f 2021-08-27 stsp branch, as of the last time
2951 a099809f 2021-08-27 stsp .Cm got fetch
2954 a099809f 2021-08-27 stsp .Dl $ got log -c origin/master | less
2956 a099809f 2021-08-27 stsp As shown here, most commands accept abbreviated reference names such as
2957 ff2cf171 2019-07-28 stsp .Dq origin/master
2958 a099809f 2021-08-27 stsp instead of
2959 a099809f 2021-08-27 stsp .Dq refs/remotes/origin/master .
2960 a099809f 2021-08-27 stsp The latter is only needed in case of ambiguity.
2962 a099809f 2021-08-27 stsp .Cm got rebase
2963 a099809f 2021-08-27 stsp must be used to merge changes which are visible on the
2964 a099809f 2021-08-27 stsp .Dq origin/master
2965 a099809f 2021-08-27 stsp branch into the
2966 a099809f 2021-08-27 stsp .Dq master
2968 7b0db533 2020-02-04 stsp This will also merge local changes, if any, with the incoming changes:
2970 ff2cf171 2019-07-28 stsp .Dl $ got update -b origin/master
2971 ff2cf171 2019-07-28 stsp .Dl $ got rebase master
2973 a099809f 2021-08-27 stsp In order to make changes committed to the
2974 a099809f 2021-08-27 stsp .Dq unified-buffer-cache
2975 a099809f 2021-08-27 stsp visible on the
2976 a099809f 2021-08-27 stsp .Dq master
2977 a099809f 2021-08-27 stsp branch, the
2978 a099809f 2021-08-27 stsp .Dq unified-buffer-cache
2979 a099809f 2021-08-27 stsp branch must first be rebased onto the
2980 a099809f 2021-08-27 stsp .Dq master
2983 a099809f 2021-08-27 stsp .Dl $ got update -b master
2984 a099809f 2021-08-27 stsp .Dl $ got rebase unified-buffer-cache
2986 a099809f 2021-08-27 stsp Changes on the
2987 a099809f 2021-08-27 stsp .Dq unified-buffer-cache
2988 a099809f 2021-08-27 stsp branch can now be made visible on the
2989 a099809f 2021-08-27 stsp .Dq master
2990 a099809f 2021-08-27 stsp branch with
2991 a099809f 2021-08-27 stsp .Cm got integrate .
2992 a099809f 2021-08-27 stsp Because the rebase operation switched the work tree to the
2993 a099809f 2021-08-27 stsp .Dq unified-buffer-cache
2994 4b06140e 2022-03-22 thomas branch, the work tree must be switched back to the
2995 a099809f 2021-08-27 stsp .Dq master
2996 a099809f 2021-08-27 stsp branch first:
2998 a099809f 2021-08-27 stsp .Dl $ got update -b master
2999 a099809f 2021-08-27 stsp .Dl $ got integrate unified-buffer-cache
3002 083957f4 2020-02-24 stsp .Dq master
3003 083957f4 2020-02-24 stsp branch, log messages for local changes can now be amended with
3005 083957f4 2020-02-24 stsp by other developers and any other important new information:
3007 083957f4 2020-02-24 stsp .Dl $ got update -c origin/master
3008 083957f4 2020-02-24 stsp .Dl $ got histedit -m
3010 4b06140e 2022-03-22 thomas If the remote repository offers write access, local changes on the
3011 ff2cf171 2019-07-28 stsp .Dq master
3012 a099809f 2021-08-27 stsp branch can be sent to the remote repository with
3013 ac93b2c5 2021-10-08 thomas .Cm got send .
3014 ac93b2c5 2021-10-08 thomas Usually,
3015 a099809f 2021-08-27 stsp .Cm got send
3016 a099809f 2021-08-27 stsp can be run without further arguments.
3017 a099809f 2021-08-27 stsp The arguments shown here match defaults, provided the work tree's
3018 a099809f 2021-08-27 stsp current branch is the
3019 a099809f 2021-08-27 stsp .Dq master
3022 a099809f 2021-08-27 stsp .Dl $ got send -b master origin
3024 4b06140e 2022-03-22 thomas If the remote repository requires the HTTPS protocol, the
3025 a099809f 2021-08-27 stsp .Xr git-push 1
3026 a099809f 2021-08-27 stsp command must be used instead:
3028 a099809f 2021-08-27 stsp .Dl $ cd /var/git/src.git
3029 ff2cf171 2019-07-28 stsp .Dl $ git push origin master
3030 5c860e29 2018-03-12 stsp .Sh SEE ALSO
3031 0a79feb1 2021-04-10 stsp .Xr gotadmin 1 ,
3032 2312fc47 2019-07-15 stsp .Xr tog 1 ,
3033 2312fc47 2019-07-15 stsp .Xr git-repository 5 ,
3034 257add31 2020-09-09 stsp .Xr got-worktree 5 ,
3035 257add31 2020-09-09 stsp .Xr got.conf 5
3036 1a208aaf 2018-04-01 stsp .Sh AUTHORS
3037 1a208aaf 2018-04-01 stsp .An Stefan Sperling Aq Mt stsp@openbsd.org
3038 1a208aaf 2018-04-01 stsp .An Martin Pieuchot Aq Mt mpi@openbsd.org
3039 bc3056e3 2019-08-18 stsp .An Joshua Stein Aq Mt jcs@openbsd.org
3040 83b416ed 2020-03-18 stsp .An Ori Bernstein Aq Mt ori@openbsd.org
3041 fa6e0e48 2019-05-23 stsp .Sh CAVEATS
3043 cc63216e 2020-12-26 stsp is a work-in-progress and some features remain to be implemented.
3045 fa6e0e48 2019-05-23 stsp At present, the user has to fall back on
3047 cc63216e 2020-12-26 stsp to perform some tasks.
3048 cc63216e 2020-12-26 stsp In particular:
3049 cc63216e 2020-12-26 stsp .Bl -bullet
3051 cc63216e 2020-12-26 stsp Reading from remote repositories over HTTP or HTTPS protocols requires
3052 cc63216e 2020-12-26 stsp .Xr git-clone 1
3054 cc63216e 2020-12-26 stsp .Xr git-fetch 1 .
3056 a099809f 2021-08-27 stsp Writing to remote repositories over HTTP or HTTPS protocols requires
3057 cc63216e 2020-12-26 stsp .Xr git-push 1 .
3059 22a38a43 2021-09-28 thomas The creation of merge commits with more than two parent commits requires
3060 cc63216e 2020-12-26 stsp .Xr git-merge 1 .
3062 cc63216e 2020-12-26 stsp In situations where files or directories were moved around
3064 cc63216e 2020-12-26 stsp will not automatically merge changes to new locations and
3066 cc63216e 2020-12-26 stsp will usually produce better results.