Blob


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