2 .\" Copyright (c) 2020 Stefan Sperling <stsp@openbsd.org>
4 .\" Permission to use, copy, modify, and distribute this software for any
5 .\" purpose with or without fee is hereby granted, provided that the above
6 .\" copyright notice and this permission notice appear in all copies.
8 .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13 .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14 .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
21 .Nd Game of Trees configuration file
24 is the run-time configuration file for
28 may be present in the root directory of a Git repository for
29 repository-wide settings, or in the
31 meta-data directory of a work tree to override repository-wide
34 commands executed within this work tree.
36 The file format is line-based, with one configuration directive per line.
37 Any lines beginning with a
39 are treated as comments and ignored.
41 The available configuration directives are as follows:
43 .It Ic author Dq Real Name <email address>
44 Configure the author's name and email address for
48 when operating on this repository.
49 Author information specified here overrides the
55 may fail to parse commits without an email address in author data,
57 attempts to reject author information with a missing email address.
58 .It Ic remote Ar name Brq ...
59 Define a remote repository.
62 can be used to refer to the remote repository on the command line of
65 Information about this repository is declared in a block of options
66 enclosed in curly brackets:
68 .It Ic server Ar hostname
69 Defines the hostname to use for contacting the remote repository's server.
70 .It Ic repository Ar path
71 Defines the path to the repository on the remote repository's server.
72 .It Ic protocol Ar scheme
73 Defines the protocol to use for communicating with the remote repository's
76 The following protocol schemes are supported:
77 .Bl -tag -width git+ssh
79 The Git protocol as implemented by the
82 Use of this protocol is discouraged since it supports neither authentication
85 The Git protocol wrapped in an authenticated and encrypted
88 With this protocol the hostname may contain an embedded username for
93 Short alias for git+ssh.
96 Defines the port to use for connecting to the remote repository's server.
99 can be specified by number or name.
100 The port name to number mappings are found in the file
105 If not specified, the default port of the specified
108 .It Ic branch Brq Ar branch ...
109 Specify one or more branches which
111 should fetch from the remote repository by default.
112 The list of branches specified here can be overridden at the
114 command line with the
117 .It Ic mirror-references Ar yes | no
118 This option controls the behaviour of
120 when updating references.
121 .Sy Enabling this option can lead to the loss of local commits.
122 Maintaining custom changes in a mirror repository is therefore discouraged.
124 If this option is not specified or set to
127 will map references of the remote repository into the local repository's
131 If this option is set to
135 namespace will be updated directly to match the corresponding branches in
136 the remote repository.
139 Configure author information:
140 .Bd -literal -offset indent
141 author "Flan Hacker <flan_hacker@openbsd.org>"
144 Remote repository specification for the Game of Trees repository:
145 .Bd -literal -offset indent
147 server git.gameoftrees.org
154 Mirror the OpenBSD src repository from Github:
155 .Bd -literal -offset indent
157 repository "openbsd/src"
158 server git@github.com
160 mirror-references yes
164 .Bl -tag -width Ds -compact
168 located in the root directory of a Git repository supersedes any relevant
178 meta-data directory of a
180 work tree supersedes any relevant settings in the repository's
182 configuration file and Git's
188 .Xr git-repository 5 ,
192 offers no way to configure the editor spawned by
198 This is deliberate and prevents potential arbitrary command execution
199 as another user when repositories or work trees are shared between users.
200 Users should set their
204 environment variables instead.