Blame


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