Blame


1 030916b5 2018-07-12 stsp .\"
2 030916b5 2018-07-12 stsp .\" Copyright (c) 2018 Stefan Sperling
3 030916b5 2018-07-12 stsp .\"
4 030916b5 2018-07-12 stsp .\" Permission to use, copy, modify, and distribute this software for any
5 030916b5 2018-07-12 stsp .\" purpose with or without fee is hereby granted, provided that the above
6 030916b5 2018-07-12 stsp .\" copyright notice and this permission notice appear in all copies.
7 030916b5 2018-07-12 stsp .\"
8 030916b5 2018-07-12 stsp .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 030916b5 2018-07-12 stsp .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 030916b5 2018-07-12 stsp .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 030916b5 2018-07-12 stsp .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 030916b5 2018-07-12 stsp .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13 030916b5 2018-07-12 stsp .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14 030916b5 2018-07-12 stsp .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15 030916b5 2018-07-12 stsp .\"
16 030916b5 2018-07-12 stsp .Dd $Mdocdate$
17 030916b5 2018-07-12 stsp .Dt TOG 1
18 030916b5 2018-07-12 stsp .Os
19 030916b5 2018-07-12 stsp .Sh NAME
20 030916b5 2018-07-12 stsp .Nm tog
21 aee2a8bd 2019-08-05 stsp .Nd Git repository browser
22 030916b5 2018-07-12 stsp .Sh SYNOPSIS
23 030916b5 2018-07-12 stsp .Nm
24 0a58e722 2022-10-04 thomas .Op Fl hV
25 0a58e722 2022-10-04 thomas .Ar command
26 030916b5 2018-07-12 stsp .Op Ar arg ...
27 ee85c5e8 2020-02-29 stsp .Pp
28 ee85c5e8 2020-02-29 stsp .Nm
29 ee85c5e8 2020-02-29 stsp .Ar path
30 030916b5 2018-07-12 stsp .Sh DESCRIPTION
31 030916b5 2018-07-12 stsp .Nm
32 aee2a8bd 2019-08-05 stsp is an interactive read-only browser for Git repositories.
33 030916b5 2018-07-12 stsp This repository format is described in
34 5e5560e1 2018-08-01 stsp .Xr git-repository 5 .
35 030916b5 2018-07-12 stsp .Pp
36 030916b5 2018-07-12 stsp .Nm
37 0cf4efb1 2018-09-29 stsp supports several types of views which display repository data:
38 87aa0e98 2018-08-18 stsp .Bl -tag -width Ds
39 9419758a 2019-03-27 stsp .It Log view
40 87aa0e98 2018-08-18 stsp Displays commits in the repository's history.
41 87aa0e98 2018-08-18 stsp This view is displayed initially if no
42 87aa0e98 2018-08-18 stsp .Ar command
43 ee85c5e8 2020-02-29 stsp is specified, or if just a
44 ee85c5e8 2020-02-29 stsp .Ar path
45 87aa0e98 2018-08-18 stsp is specified.
46 9419758a 2019-03-27 stsp .It Diff view
47 87aa0e98 2018-08-18 stsp Displays changes made in a particular commit.
48 9419758a 2019-03-27 stsp .It Blame view
49 87aa0e98 2018-08-18 stsp Displays the line-by-line history of a file.
50 9419758a 2019-03-27 stsp .It Tree view
51 87aa0e98 2018-08-18 stsp Displays the tree corresponding to a particular commit.
52 38cb327b 2020-11-24 stsp .It Ref view
53 38cb327b 2020-11-24 stsp Displays references in the repository.
54 87aa0e98 2018-08-18 stsp .El
55 87aa0e98 2018-08-18 stsp .Pp
56 87aa0e98 2018-08-18 stsp .Nm
57 87aa0e98 2018-08-18 stsp provides global and command-specific key bindings and options.
58 07b0611c 2022-06-23 thomas Some command-specific key bindings may be prefixed with an integer, which is
59 07b0611c 2022-06-23 thomas denoted by N in the descriptions below, and is used as a modifier to the
60 07b0611c 2022-06-23 thomas operation as indicated.
61 07b0611c 2022-06-23 thomas .Nm
62 fa502711 2022-07-03 thomas will echo digits to the screen when count modifiers are entered, and complete
63 fa502711 2022-07-03 thomas the sequence upon input of the first non-numeric character.
64 fa502711 2022-07-03 thomas Count modifiers can be aborted by entering an unmapped key.
65 634cb454 2022-07-03 thomas Once a compound command is executed, the operation can be cancelled with
66 634cb454 2022-07-03 thomas .Cm C-g
67 634cb454 2022-07-03 thomas or
68 634cb454 2022-07-03 thomas .Cm Backspace .
69 ee0cf61c 2022-10-05 thomas .Pp
70 ee0cf61c 2022-10-05 thomas Global options must precede the command name, and are as follows:
71 ee0cf61c 2022-10-05 thomas .Bl -tag -width tenletters
72 ee0cf61c 2022-10-05 thomas .It Fl h
73 ee0cf61c 2022-10-05 thomas Display usage information.
74 ee0cf61c 2022-10-05 thomas .It Fl V , -version
75 ee0cf61c 2022-10-05 thomas Display program version and exit immediately.
76 ee0cf61c 2022-10-05 thomas .El
77 7faa2de4 2022-07-12 thomas .Pp
78 87aa0e98 2018-08-18 stsp The global key bindings are:
79 87aa0e98 2018-08-18 stsp .Bl -tag -width Ds
80 fc2737d5 2022-09-15 thomas .It Cm H, F1
81 fc2737d5 2022-09-15 thomas Display run-time help.
82 fc2737d5 2022-09-15 thomas Key bindings for the focussed view will be displayed.
83 fc2737d5 2022-09-15 thomas Pressing this again inside the help view will toggle the display of
84 fc2737d5 2022-09-15 thomas key bindings for all
85 fc2737d5 2022-09-15 thomas .Nm
86 fc2737d5 2022-09-15 thomas views.
87 87aa0e98 2018-08-18 stsp .It Cm Q
88 87aa0e98 2018-08-18 stsp Quit
89 87aa0e98 2018-08-18 stsp .Nm .
90 87aa0e98 2018-08-18 stsp .It Cm q
91 87aa0e98 2018-08-18 stsp Quit the view which is in focus.
92 87aa0e98 2018-08-18 stsp .It Cm Tab
93 c0d30c23 2018-10-07 stsp Switch focus between views.
94 1c5e5faa 2022-06-23 thomas .It Cm F
95 c0d30c23 2018-10-07 stsp Toggle fullscreen mode for a split-screen view.
96 e9b3576f 2019-03-27 stsp .Nm
97 b1c950bf 2022-07-12 thomas will automatically use vertical split-screen views if the size of the
98 b1c950bf 2022-07-12 thomas terminal window is sufficiently large.
99 64486692 2022-07-07 thomas .It Cm S
100 569abcd7 2022-07-12 thomas Switch the current split-screen layout, and render all active views in
101 569abcd7 2022-07-12 thomas this new layout.
102 b1c950bf 2022-07-12 thomas The split-screen layout can be either vertical or horizontal.
103 569abcd7 2022-07-12 thomas If the terminal is not wide enough when switching to a vertical split,
104 569abcd7 2022-07-12 thomas views will render in fullscreen.
105 53d2bdd3 2022-07-10 thomas .It Cm -
106 53d2bdd3 2022-07-10 thomas When in a split-screen view, decrease the size of the focussed split
107 53d2bdd3 2022-07-10 thomas N increments (default: 1).
108 53d2bdd3 2022-07-10 thomas .It Cm +
109 53d2bdd3 2022-07-10 thomas When in a split-screen view, increase the size of the focussed split
110 53d2bdd3 2022-07-10 thomas N increments (default: 1).
111 07dd3ed3 2022-08-06 thomas .It Cm G
112 07dd3ed3 2022-08-06 thomas Go to line N in the view (default: last line).
113 07dd3ed3 2022-08-06 thomas .It Cm g
114 07dd3ed3 2022-08-06 thomas Go to line N in the view (default: first line).
115 c72de8ab 2023-02-03 thomas .It Cm Right-arrow, l
116 c72de8ab 2023-02-03 thomas Scroll view to the right N increments (default: 1).
117 c72de8ab 2023-02-03 thomas .br
118 c72de8ab 2023-02-03 thomas Output moves left on the screen.
119 c72de8ab 2023-02-03 thomas .It Cm Left-arrow, h
120 c72de8ab 2023-02-03 thomas Scroll view to the left N increments (default: 1).
121 c72de8ab 2023-02-03 thomas .br
122 c72de8ab 2023-02-03 thomas Output moves right on the screen.
123 c72de8ab 2023-02-03 thomas .It Cm $
124 c72de8ab 2023-02-03 thomas Scroll view to the rightmost position.
125 c72de8ab 2023-02-03 thomas .It Cm 0
126 c72de8ab 2023-02-03 thomas Scroll view left to the start of the line.
127 030916b5 2018-07-12 stsp .El
128 030916b5 2018-07-12 stsp .Pp
129 030916b5 2018-07-12 stsp The commands for
130 030916b5 2018-07-12 stsp .Nm
131 030916b5 2018-07-12 stsp are as follows:
132 030916b5 2018-07-12 stsp .Bl -tag -width blame
133 56c96eff 2022-08-30 thomas .It Xo
134 56c96eff 2022-08-30 thomas .Cm log
135 56c96eff 2022-08-30 thomas .Op Fl b
136 56c96eff 2022-08-30 thomas .Op Fl c Ar commit
137 56c96eff 2022-08-30 thomas .Op Fl r Ar repository-path
138 56c96eff 2022-08-30 thomas .Op Ar path
139 56c96eff 2022-08-30 thomas .Xc
140 030916b5 2018-07-12 stsp Display history of a repository.
141 ecb28ae0 2018-07-16 stsp If a
142 ecb28ae0 2018-07-16 stsp .Ar path
143 ecb28ae0 2018-07-16 stsp is specified, show only commits which modified this path.
144 dc990cbf 2020-02-22 stsp If invoked in a work tree, the
145 dc990cbf 2020-02-22 stsp .Ar path
146 dc990cbf 2020-02-22 stsp is interpreted relative to the current working directory,
147 dc990cbf 2020-02-22 stsp and the work tree's path prefix is implicitly prepended.
148 dc990cbf 2020-02-22 stsp Otherwise, the path is interpreted relative to the repository root.
149 349dfd1e 2023-07-23 thomas .Pp
150 349dfd1e 2023-07-23 thomas If invoked in a work tree, the log entry of the work tree's base commit will
151 349dfd1e 2023-07-23 thomas be prefixed with one of the following annotations:
152 349dfd1e 2023-07-23 thomas .Bl -column YXZ description
153 349dfd1e 2023-07-23 thomas .It * Ta work tree's base commit and the base commit of all tracked files
154 349dfd1e 2023-07-23 thomas matches the branch tip
155 349dfd1e 2023-07-23 thomas .It \(a~ Ta work tree comprises mixed commits or its base commit is out-of-date
156 349dfd1e 2023-07-23 thomas .El
157 030916b5 2018-07-12 stsp .Pp
158 030916b5 2018-07-12 stsp This command is also executed if no explicit command is specified.
159 030916b5 2018-07-12 stsp .Pp
160 030916b5 2018-07-12 stsp The key bindings for
161 030916b5 2018-07-12 stsp .Cm tog log
162 07b0611c 2022-06-23 thomas are as follows (N denotes optional prefixed count modifier):
163 030916b5 2018-07-12 stsp .Bl -tag -width Ds
164 f7140bf5 2021-10-17 thomas .It Cm Down-arrow, j, >, Full stop, Ctrl-n
165 07b0611c 2022-06-23 thomas Move the selection cursor down N lines (default: 1).
166 f7140bf5 2021-10-17 thomas .It Cm Up-arrow, k, <, Comma, Ctrl-p
167 07b0611c 2022-06-23 thomas Move the selection cursor up N lines (default: 1).
168 4c2d69cb 2022-06-23 thomas .It Cm Page-down, Space, Ctrl+f, f
169 07b0611c 2022-06-23 thomas Move the selection cursor down N pages (default: 1).
170 1c5e5faa 2022-06-23 thomas .It Cm Page-up, Ctrl+b, b
171 07b0611c 2022-06-23 thomas Move the selection cursor up N pages (default: 1).
172 23427b14 2022-06-23 thomas .It Cm Ctrl+d, d
173 07b0611c 2022-06-23 thomas Move the selection cursor down N half pages (default: 1).
174 23427b14 2022-06-23 thomas .It Cm Ctrl+u, u
175 07b0611c 2022-06-23 thomas Move the selection cursor up N half pages (default: 1).
176 aa7a1117 2023-01-09 thomas .It Cm Home, =
177 912a3f79 2021-08-30 j Move the cursor to the newest commit.
178 aa7a1117 2023-01-09 thomas .It Cm End, *
179 912a3f79 2021-08-30 j Move the cursor to the oldest commit.
180 1dd93b2a 2021-08-30 stsp This will traverse all commits on the current branch which may take
181 1dd93b2a 2021-08-30 stsp a long time depending on the number of commits in branch history.
182 4b06140e 2022-03-22 thomas If needed, this operation can be cancelled with
183 634cb454 2022-07-03 thomas .Cm C-g
184 634cb454 2022-07-03 thomas or
185 9ebbe6e1 2021-08-30 stsp .Cm Backspace .
186 aa7a1117 2023-01-09 thomas .It Cm g
187 aa7a1117 2023-01-09 thomas Move the cursor to commit N (default: 1).
188 aa7a1117 2023-01-09 thomas .It Cm G
189 aa7a1117 2023-01-09 thomas Like
190 aa7a1117 2023-01-09 thomas .Cm g
191 aa7a1117 2023-01-09 thomas but defaults to the oldest commit.
192 4c2d69cb 2022-06-23 thomas .It Cm Enter
193 c0d30c23 2018-10-07 stsp Open a
194 030916b5 2018-07-12 stsp .Cm diff
195 030916b5 2018-07-12 stsp view showing file changes made in the currently selected commit.
196 1be4947a 2022-07-22 thomas .It Cm T
197 a60a9dc4 2019-05-13 jcs Open a
198 030916b5 2018-07-12 stsp .Cm tree
199 030916b5 2018-07-12 stsp view showing the tree for the currently selected commit.
200 5036bf37 2018-09-24 stsp .It Cm Backspace
201 26f0cb24 2021-08-30 j Show log entries for the parent directory of the currently selected path.
202 26f0cb24 2021-08-30 j However when an active search is in progress or when additional commits
203 26f0cb24 2021-08-30 j are loaded,
204 678cbce5 2019-07-28 stsp .Cm Backspace
205 26f0cb24 2021-08-30 j aborts the running operation.
206 60493ae3 2019-06-20 stsp .It Cm /
207 60493ae3 2019-06-20 stsp Prompt for a search pattern and start searching for matching commits.
208 60493ae3 2019-06-20 stsp The search pattern is an extended regular expression which is matched
209 df0b3d8a 2019-06-28 stsp against a commit's author name, committer name, log message, and
210 df0b3d8a 2019-06-28 stsp commit ID SHA1 hash.
211 e6c76b79 2019-06-21 stsp Regular expression syntax is documented in
212 e6c76b79 2019-06-21 stsp .Xr re_format 7 .
213 7e8004ba 2022-09-11 thomas .It Cm &
214 aadc20e8 2022-09-23 thomas Prompt for a pattern and limit the log view's list of commits to those
215 aadc20e8 2022-09-23 thomas which match the pattern.
216 aadc20e8 2022-09-23 thomas If no pattern is specified, i.e. the
217 aadc20e8 2022-09-23 thomas .Cm &
218 aadc20e8 2022-09-23 thomas prompt is immediately closed with the Enter key, then the pattern is
219 aadc20e8 2022-09-23 thomas cleared.
220 aadc20e8 2022-09-23 thomas Until the pattern is cleared, the limited list of commits replaces the
221 aadc20e8 2022-09-23 thomas full list of commits for all operations supported by the log view.
222 aadc20e8 2022-09-23 thomas For example, a search started with
223 7e8004ba 2022-09-11 thomas .Cm /
224 aadc20e8 2022-09-23 thomas will search the limited list of commits, rather than searching all commits.
225 aadc20e8 2022-09-23 thomas The pattern is an extended regular expression which is matched
226 aadc20e8 2022-09-23 thomas against a commit's author name, committer name, log message, and
227 aadc20e8 2022-09-23 thomas commit ID SHA1 hash.
228 aadc20e8 2022-09-23 thomas Regular expression syntax is documented in
229 aadc20e8 2022-09-23 thomas .Xr re_format 7 .
230 60493ae3 2019-06-20 stsp .It Cm n
231 07b0611c 2022-06-23 thomas Find the Nth next commit which matches the current search pattern (default: 1).
232 07b0611c 2022-06-23 thomas .br
233 634cb454 2022-07-03 thomas Searching continues until either a match is found or
234 634cb454 2022-07-03 thomas .Cm C-g
235 634cb454 2022-07-03 thomas or the
236 678cbce5 2019-07-28 stsp .Cm Backspace
237 678cbce5 2019-07-28 stsp key is pressed.
238 b1bf1435 2019-06-21 stsp .It Cm N
239 07b0611c 2022-06-23 thomas Find the Nth previous commit which matches the current search pattern
240 07b0611c 2022-06-23 thomas (default: 1).
241 07b0611c 2022-06-23 thomas .br
242 634cb454 2022-07-03 thomas Searching continues until either a match is found or
243 634cb454 2022-07-03 thomas .Cm C-g
244 634cb454 2022-07-03 thomas or the
245 678cbce5 2019-07-28 stsp .Cm Backspace
246 678cbce5 2019-07-28 stsp key is pressed.
247 bf0668dd 2019-06-26 stsp .It Cm Ctrl+l
248 01ca22b1 2020-12-07 stsp Reload the
249 01ca22b1 2020-12-07 stsp .Cm log
250 01ca22b1 2020-12-07 stsp view with new commits found in the repository.
251 b672a97a 2020-01-27 stsp .It Cm B
252 01ca22b1 2020-12-07 stsp Reload the
253 01ca22b1 2020-12-07 stsp .Cm log
254 01ca22b1 2020-12-07 stsp view and toggle display of merged commits.
255 b672a97a 2020-01-27 stsp The
256 b672a97a 2020-01-27 stsp .Fl b
257 b672a97a 2020-01-27 stsp option determines whether merged commits are displayed initially.
258 1be4947a 2022-07-22 thomas .It Cm R
259 38cb327b 2020-11-24 stsp Open a
260 38cb327b 2020-11-24 stsp .Cm ref
261 38cb327b 2020-11-24 stsp view listing all references in the repository.
262 38cb327b 2020-11-24 stsp This can then be used to open a new
263 38cb327b 2020-11-24 stsp .Cm log
264 38cb327b 2020-11-24 stsp view for arbitrary branches and tags.
265 f69c5a46 2022-07-19 thomas .It Cm @
266 8eca0bdb 2023-01-02 thomas Toggle between showing the committer name and the author name.
267 030916b5 2018-07-12 stsp .El
268 030916b5 2018-07-12 stsp .Pp
269 030916b5 2018-07-12 stsp The options for
270 030916b5 2018-07-12 stsp .Cm tog log
271 030916b5 2018-07-12 stsp are as follows:
272 030916b5 2018-07-12 stsp .Bl -tag -width Ds
273 b672a97a 2020-01-27 stsp .It Fl b
274 1137e0ae 2020-01-27 stsp Display individual commits which were merged into the current branch
275 1137e0ae 2020-01-27 stsp from other branches.
276 b672a97a 2020-01-27 stsp By default,
277 b672a97a 2020-01-27 stsp .Cm tog log
278 b672a97a 2020-01-27 stsp shows the linear history of the current branch only.
279 b672a97a 2020-01-27 stsp The
280 b672a97a 2020-01-27 stsp .Cm B
281 b672a97a 2020-01-27 stsp key binding can be used to toggle display of merged commits at run-time.
282 030916b5 2018-07-12 stsp .It Fl c Ar commit
283 030916b5 2018-07-12 stsp Start traversing history at the specified
284 030916b5 2018-07-12 stsp .Ar commit .
285 66b04f8f 2023-07-19 thomas The expected argument is a commit ID SHA1 hash, or a reference name or keyword
286 66b04f8f 2023-07-19 thomas which will be resolved to a commit ID.
287 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
288 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
289 66b04f8f 2023-07-19 thomas The keywords
290 66b04f8f 2023-07-19 thomas .Qq :base
291 66b04f8f 2023-07-19 thomas and
292 66b04f8f 2023-07-19 thomas .Qq :head
293 66b04f8f 2023-07-19 thomas resolve to the work tree's base commit and branch head, respectively.
294 66b04f8f 2023-07-19 thomas The former is only valid if invoked in a work tree, while the latter will
295 66b04f8f 2023-07-19 thomas resolve to the tip of the work tree's current branch if invoked in a
296 66b04f8f 2023-07-19 thomas work tree, otherwise it will resolve to the repository's HEAD reference.
297 66b04f8f 2023-07-19 thomas Keywords and references may be appended with
298 66b04f8f 2023-07-19 thomas .Qq :+
299 66b04f8f 2023-07-19 thomas or
300 66b04f8f 2023-07-19 thomas .Qq :-
301 66b04f8f 2023-07-19 thomas modifiers and an optional integer N to denote the
302 66b04f8f 2023-07-19 thomas Nth descendant or antecedent by first parent traversal, respectively;
303 66b04f8f 2023-07-19 thomas for example,
304 66b04f8f 2023-07-19 thomas .Sy :head:-2
305 66b04f8f 2023-07-19 thomas denotes the work tree branch head's 2nd generation ancestor, and
306 66b04f8f 2023-07-19 thomas .Sy :base:+4
307 66b04f8f 2023-07-19 thomas denotes the 4th generation descendant of the work tree's base commit.
308 66b04f8f 2023-07-19 thomas Similarly,
309 66b04f8f 2023-07-19 thomas .Sy foobar:+3
310 66b04f8f 2023-07-19 thomas will denote the 3rd generation descendant of the commit resolved by the
311 66b04f8f 2023-07-19 thomas .Qq foobar
312 66b04f8f 2023-07-19 thomas reference.
313 66b04f8f 2023-07-19 thomas A
314 66b04f8f 2023-07-19 thomas .Qq :+
315 66b04f8f 2023-07-19 thomas or
316 66b04f8f 2023-07-19 thomas .Qq :-
317 66b04f8f 2023-07-19 thomas modifier without a trailing integer has an implicit
318 66b04f8f 2023-07-19 thomas .Qq 1
319 66b04f8f 2023-07-19 thomas appended
320 66b04f8f 2023-07-19 thomas .Po e.g.,
321 66b04f8f 2023-07-19 thomas .Sy :base:+
322 66b04f8f 2023-07-19 thomas is equivalent to
323 66b04f8f 2023-07-19 thomas .Sy :base:+1
324 66b04f8f 2023-07-19 thomas .Pc .
325 ecb28ae0 2018-07-16 stsp .It Fl r Ar repository-path
326 ecb28ae0 2018-07-16 stsp Use the repository at the specified path.
327 ecb28ae0 2018-07-16 stsp If not specified, assume the repository is located at or above the current
328 ecb28ae0 2018-07-16 stsp working directory.
329 212b39d1 2020-02-24 naddy If this directory is a
330 212b39d1 2020-02-24 naddy .Xr got 1
331 212b39d1 2020-02-24 naddy work tree, use the repository path associated with this work tree.
332 030916b5 2018-07-12 stsp .El
333 56c96eff 2022-08-30 thomas .It Xo
334 56c96eff 2022-08-30 thomas .Cm diff
335 56c96eff 2022-08-30 thomas .Op Fl aw
336 56c96eff 2022-08-30 thomas .Op Fl C Ar number
337 56c96eff 2022-08-30 thomas .Op Fl r Ar repository-path
338 56c96eff 2022-08-30 thomas .Ar object1
339 56c96eff 2022-08-30 thomas .Ar object2
340 56c96eff 2022-08-30 thomas .Xc
341 030916b5 2018-07-12 stsp Display the differences between two objects in the repository.
342 66b04f8f 2023-07-19 thomas Treat each of the two arguments as a reference, a tag name, an object
343 66b04f8f 2023-07-19 thomas ID SHA1 hash, or a keyword and display differences between the corresponding
344 66b04f8f 2023-07-19 thomas objects.
345 3dbaef42 2020-11-24 stsp Both objects must be of the same type (blobs, trees, or commits).
346 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
347 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
348 66b04f8f 2023-07-19 thomas The keywords
349 66b04f8f 2023-07-19 thomas .Qq :base
350 66b04f8f 2023-07-19 thomas and
351 66b04f8f 2023-07-19 thomas .Qq :head
352 66b04f8f 2023-07-19 thomas resolve to the work tree's base commit and branch head, respectively.
353 66b04f8f 2023-07-19 thomas The former is only valid if invoked in a work tree, while the latter will
354 66b04f8f 2023-07-19 thomas resolve to the tip of the work tree's current branch if invoked in a
355 66b04f8f 2023-07-19 thomas work tree, otherwise it will resolve to the repository's HEAD reference.
356 66b04f8f 2023-07-19 thomas Keywords and references may be appended with
357 66b04f8f 2023-07-19 thomas .Qq :+
358 66b04f8f 2023-07-19 thomas or
359 66b04f8f 2023-07-19 thomas .Qq :-
360 66b04f8f 2023-07-19 thomas modifiers and an optional integer N to denote the
361 66b04f8f 2023-07-19 thomas Nth descendant or antecedent by first parent traversal, respectively;
362 66b04f8f 2023-07-19 thomas for example,
363 66b04f8f 2023-07-19 thomas .Sy :head:-2
364 66b04f8f 2023-07-19 thomas denotes the work tree branch head's 2nd generation ancestor, and
365 66b04f8f 2023-07-19 thomas .Sy :base:+4
366 66b04f8f 2023-07-19 thomas denotes the 4th generation descendant of the work tree's base commit.
367 66b04f8f 2023-07-19 thomas Similarly,
368 66b04f8f 2023-07-19 thomas .Sy foobar:+3
369 66b04f8f 2023-07-19 thomas will denote the 3rd generation descendant of the commit resolved by the
370 66b04f8f 2023-07-19 thomas .Qq foobar
371 66b04f8f 2023-07-19 thomas reference.
372 66b04f8f 2023-07-19 thomas A
373 66b04f8f 2023-07-19 thomas .Qq :+
374 66b04f8f 2023-07-19 thomas or
375 66b04f8f 2023-07-19 thomas .Qq :-
376 66b04f8f 2023-07-19 thomas modifier without a trailing integer has an implicit
377 66b04f8f 2023-07-19 thomas .Qq 1
378 66b04f8f 2023-07-19 thomas appended
379 66b04f8f 2023-07-19 thomas .Po e.g.,
380 66b04f8f 2023-07-19 thomas .Sy :base:+
381 66b04f8f 2023-07-19 thomas is equivalent to
382 66b04f8f 2023-07-19 thomas .Sy :base:+1
383 66b04f8f 2023-07-19 thomas .Pc .
384 030916b5 2018-07-12 stsp .Pp
385 030916b5 2018-07-12 stsp The key bindings for
386 030916b5 2018-07-12 stsp .Cm tog diff
387 07b0611c 2022-06-23 thomas are as follows (N denotes optional prefixed count modifier):
388 030916b5 2018-07-12 stsp .Bl -tag -width Ds
389 64453f7e 2020-11-21 stsp .It Cm a
390 64453f7e 2020-11-21 stsp Toggle treatment of file contents as ASCII text even if binary data was
391 64453f7e 2020-11-21 stsp detected.
392 f7140bf5 2021-10-17 thomas .It Cm Down-arrow, j, Ctrl-n
393 07b0611c 2022-06-23 thomas Scroll down N lines (default: 1).
394 f7140bf5 2021-10-17 thomas .It Cm Up-arrow, k, Ctrl-p
395 07b0611c 2022-06-23 thomas Scroll up N lines (default: 1).
396 1c5e5faa 2022-06-23 thomas .It Cm Page-down, Space, Ctrl+f, f
397 07b0611c 2022-06-23 thomas Scroll down N pages (default: 1).
398 1c5e5faa 2022-06-23 thomas .It Cm Page-up, Ctrl+b, b
399 07b0611c 2022-06-23 thomas Scroll up N pages (default: 1).
400 23427b14 2022-06-23 thomas .It Cm Ctrl+d, d
401 07b0611c 2022-06-23 thomas Scroll down N half pages (default: 1).
402 23427b14 2022-06-23 thomas .It Cm Ctrl+u, u
403 07b0611c 2022-06-23 thomas Scroll up N half pages (default: 1).
404 aa7a1117 2023-01-09 thomas .It Cm Home
405 912a3f79 2021-08-30 j Scroll to the top of the view.
406 aa7a1117 2023-01-09 thomas .It Cm End
407 912a3f79 2021-08-30 j Scroll to the bottom of the view.
408 aa7a1117 2023-01-09 thomas .It Cm g
409 aa7a1117 2023-01-09 thomas Scroll to line N (default: 1).
410 aa7a1117 2023-01-09 thomas .It Cm G
411 aa7a1117 2023-01-09 thomas Like
412 aa7a1117 2023-01-09 thomas .Cm g
413 aa7a1117 2023-01-09 thomas but defaults to the last line in the diff.
414 82c78e96 2022-08-06 thomas .It Cm \&(
415 82c78e96 2022-08-06 thomas Navigate to the Nth previous file in the diff (default: 1).
416 82c78e96 2022-08-06 thomas .It Cm \&)
417 82c78e96 2022-08-06 thomas Navigate to the Nth next file in the diff (default: 1).
418 82c78e96 2022-08-06 thomas .It Cm \&{
419 82c78e96 2022-08-06 thomas Navigate to the Nth previous hunk in the diff (default: 1).
420 82c78e96 2022-08-06 thomas .It Cm \&}
421 82c78e96 2022-08-06 thomas Navigate to the Nth next hunk in the diff (default: 1).
422 dfc23429 2019-08-11 stsp .It Cm \&[
423 07b0611c 2022-06-23 thomas Reduce diff context by N lines (default: 1).
424 dfc23429 2019-08-11 stsp .It Cm \&]
425 07b0611c 2022-06-23 thomas Increase diff context by N lines (default: 1).
426 777aae21 2022-07-20 thomas .It Cm <, Comma, K
427 01ca22b1 2020-12-07 stsp If the
428 01ca22b1 2020-12-07 stsp .Cm diff
429 01ca22b1 2020-12-07 stsp view was opened via the
430 01ca22b1 2020-12-07 stsp .Cm log
431 4fc71f3b 2022-07-12 thomas view, move to the Nth previous (younger) commit.
432 4fc71f3b 2022-07-12 thomas If the diff was opened via the
433 4fc71f3b 2022-07-12 thomas .Cm blame
434 4fc71f3b 2022-07-12 thomas view, move to the Nth previous line and load the corresponding commit
435 4fc71f3b 2022-07-12 thomas (default: 1).
436 777aae21 2022-07-20 thomas .It Cm >, Full stop, J
437 01ca22b1 2020-12-07 stsp If the
438 01ca22b1 2020-12-07 stsp .Cm diff
439 01ca22b1 2020-12-07 stsp view was opened via the
440 01ca22b1 2020-12-07 stsp .Cm log
441 4fc71f3b 2022-07-12 thomas view, move to the Nth next (older) commit.
442 4fc71f3b 2022-07-12 thomas If the diff was opened via the
443 4fc71f3b 2022-07-12 thomas .Cm blame
444 4fc71f3b 2022-07-12 thomas view, move to the Nth next line and load the corresponding commit (default: 1).
445 66dc9065 2020-02-15 stsp .It Cm /
446 0e404f95 2020-11-14 stsp Prompt for a search pattern and start searching for matching lines.
447 66dc9065 2020-02-15 stsp The search pattern is an extended regular expression.
448 66dc9065 2020-02-15 stsp Regular expression syntax is documented in
449 66dc9065 2020-02-15 stsp .Xr re_format 7 .
450 66dc9065 2020-02-15 stsp .It Cm n
451 07b0611c 2022-06-23 thomas Find the Nth next line which matches the current search pattern (default: 1).
452 66dc9065 2020-02-15 stsp .It Cm N
453 07b0611c 2022-06-23 thomas Find the Nth previous line which matches the current search pattern
454 07b0611c 2022-06-23 thomas (default: 1).
455 3dbaef42 2020-11-24 stsp .It Cm w
456 3dbaef42 2020-11-24 stsp Toggle display of whitespace-only changes.
457 adf4c9e0 2022-07-03 thomas .It Cm A
458 adf4c9e0 2022-07-03 thomas Change the diff algorithm.
459 d40a767d 2022-07-03 thomas Supported diff algorithms are Myers (quick and dirty) and
460 d40a767d 2022-07-03 thomas Patience (slow and tidy).
461 adf4c9e0 2022-07-03 thomas This is a global setting which also affects the
462 adf4c9e0 2022-07-03 thomas .Cm blame
463 adf4c9e0 2022-07-03 thomas view.
464 030916b5 2018-07-12 stsp .El
465 09b5bff8 2020-02-23 naddy .Pp
466 09b5bff8 2020-02-23 naddy The options for
467 09b5bff8 2020-02-23 naddy .Cm tog diff
468 09b5bff8 2020-02-23 naddy are as follows:
469 09b5bff8 2020-02-23 naddy .Bl -tag -width Ds
470 64453f7e 2020-11-21 stsp .It Fl a
471 64453f7e 2020-11-21 stsp Treat file contents as ASCII text even if binary data is detected.
472 3dbaef42 2020-11-24 stsp .It Fl C Ar number
473 3dbaef42 2020-11-24 stsp Set the number of context lines shown in the diff.
474 3dbaef42 2020-11-24 stsp By default, 3 lines of context are shown.
475 09b5bff8 2020-02-23 naddy .It Fl r Ar repository-path
476 09b5bff8 2020-02-23 naddy Use the repository at the specified path.
477 09b5bff8 2020-02-23 naddy If not specified, assume the repository is located at or above the current
478 09b5bff8 2020-02-23 naddy working directory.
479 212b39d1 2020-02-24 naddy If this directory is a
480 212b39d1 2020-02-24 naddy .Xr got 1
481 212b39d1 2020-02-24 naddy work tree, use the repository path associated with this work tree.
482 3dbaef42 2020-11-24 stsp .It Fl w
483 3dbaef42 2020-11-24 stsp Ignore whitespace-only changes.
484 09b5bff8 2020-02-23 naddy .El
485 56c96eff 2022-08-30 thomas .It Xo
486 56c96eff 2022-08-30 thomas .Cm blame
487 56c96eff 2022-08-30 thomas .Op Fl c Ar commit
488 56c96eff 2022-08-30 thomas .Op Fl r Ar repository-path
489 56c96eff 2022-08-30 thomas .Ar path
490 56c96eff 2022-08-30 thomas .Xc
491 030916b5 2018-07-12 stsp Display line-by-line history of a file at the specified path.
492 030916b5 2018-07-12 stsp .Pp
493 030916b5 2018-07-12 stsp The key bindings for
494 030916b5 2018-07-12 stsp .Cm tog blame
495 07b0611c 2022-06-23 thomas are as follows (N denotes optional prefixed count modifier):
496 030916b5 2018-07-12 stsp .Bl -tag -width Ds
497 f7140bf5 2021-10-17 thomas .It Cm Down-arrow, j, Ctrl-n
498 07b0611c 2022-06-23 thomas Move the selection cursor down N pages (default: 1).
499 f7140bf5 2021-10-17 thomas .It Cm Up-arrow, k, Ctrl-p
500 07b0611c 2022-06-23 thomas Move the selection cursor up N pages (default: 1).
501 1c5e5faa 2022-06-23 thomas .It Cm Page-down, Space, Ctrl+f, f
502 07b0611c 2022-06-23 thomas Move the selection cursor down N pages (default: 1).
503 1c5e5faa 2022-06-23 thomas .It Cm Page-up, Ctrl+b, b
504 07b0611c 2022-06-23 thomas Move the selection cursor up N pages (default: 1).
505 23427b14 2022-06-23 thomas .It Cm Ctrl+d, d
506 07b0611c 2022-06-23 thomas Move the selection cursor down N half pages (default: 1).
507 23427b14 2022-06-23 thomas .It Cm Ctrl+u, u
508 07b0611c 2022-06-23 thomas Move the selection cursor up N half pages (default: 1).
509 aa7a1117 2023-01-09 thomas .It Cm Home
510 4deef56f 2021-09-02 naddy Move the selection cursor to the first line of the file.
511 aa7a1117 2023-01-09 thomas .It Cm End
512 4deef56f 2021-09-02 naddy Move the selection cursor to the last line of the file.
513 aa7a1117 2023-01-09 thomas .It Cm g
514 aa7a1117 2023-01-09 thomas Move the selection cursor to line N (default: 1).
515 aa7a1117 2023-01-09 thomas .It Cm G
516 aa7a1117 2023-01-09 thomas Like
517 aa7a1117 2023-01-09 thomas .Cm g
518 aa7a1117 2023-01-09 thomas but defaults to the last line in the file.
519 030916b5 2018-07-12 stsp .It Cm Enter
520 c0d30c23 2018-10-07 stsp Open a
521 030916b5 2018-07-12 stsp .Cm diff
522 030916b5 2018-07-12 stsp view for the currently selected line's commit.
523 1c5e5faa 2022-06-23 thomas .It Cm c
524 c0d30c23 2018-10-07 stsp Reload the
525 030916b5 2018-07-12 stsp .Cm blame
526 c0d30c23 2018-10-07 stsp view with the version of the file as found in the currently
527 c0d30c23 2018-10-07 stsp selected line's commit.
528 7a2921f9 2018-07-12 stsp .It Cm p
529 c0d30c23 2018-10-07 stsp Reload the
530 7a2921f9 2018-07-12 stsp .Cm blame
531 c0d30c23 2018-10-07 stsp view with the version of the file as found in the parent commit of the
532 c0d30c23 2018-10-07 stsp currently selected line's commit.
533 1c5e5faa 2022-06-23 thomas .It Cm C
534 c0d30c23 2018-10-07 stsp Reload the
535 030916b5 2018-07-12 stsp .Cm blame
536 c0d30c23 2018-10-07 stsp view with the previously blamed commit.
537 eaeaa612 2022-07-20 thomas .It Cm L
538 eaeaa612 2022-07-20 thomas Open a
539 eaeaa612 2022-07-20 thomas .Cm log
540 eaeaa612 2022-07-20 thomas view for the currently selected annotated line.
541 6c4c42e0 2019-06-24 stsp .It Cm /
542 0e404f95 2020-11-14 stsp Prompt for a search pattern and start searching for matching lines.
543 6c4c42e0 2019-06-24 stsp The search pattern is an extended regular expression.
544 6c4c42e0 2019-06-24 stsp Regular expression syntax is documented in
545 6c4c42e0 2019-06-24 stsp .Xr re_format 7 .
546 6c4c42e0 2019-06-24 stsp .It Cm n
547 07b0611c 2022-06-23 thomas Find the Nth next line which matches the current search pattern (default: 1).
548 6c4c42e0 2019-06-24 stsp .It Cm N
549 07b0611c 2022-06-23 thomas Find the Nth previous line which matches the current search pattern
550 07b0611c 2022-06-23 thomas (default: 1).
551 adf4c9e0 2022-07-03 thomas .It Cm A
552 adf4c9e0 2022-07-03 thomas Change the diff algorithm.
553 d40a767d 2022-07-03 thomas Supported diff algorithms are Myers (quick and dirty) and
554 d40a767d 2022-07-03 thomas Patience (slow and tidy).
555 adf4c9e0 2022-07-03 thomas This is a global setting which also affects the
556 adf4c9e0 2022-07-03 thomas .Cm diff
557 adf4c9e0 2022-07-03 thomas view.
558 030916b5 2018-07-12 stsp .El
559 030916b5 2018-07-12 stsp .Pp
560 030916b5 2018-07-12 stsp The options for
561 030916b5 2018-07-12 stsp .Cm tog blame
562 030916b5 2018-07-12 stsp are as follows:
563 030916b5 2018-07-12 stsp .Bl -tag -width Ds
564 030916b5 2018-07-12 stsp .It Fl c Ar commit
565 030916b5 2018-07-12 stsp Start traversing history at the specified
566 030916b5 2018-07-12 stsp .Ar commit .
567 66b04f8f 2023-07-19 thomas The expected argument is a commit ID SHA1 hash, or a reference name or keyword
568 66b04f8f 2023-07-19 thomas which will be resolved to a commit ID.
569 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
570 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
571 66b04f8f 2023-07-19 thomas The keywords
572 66b04f8f 2023-07-19 thomas .Qq :base
573 66b04f8f 2023-07-19 thomas and
574 66b04f8f 2023-07-19 thomas .Qq :head
575 66b04f8f 2023-07-19 thomas resolve to the work tree's base commit and branch head, respectively.
576 66b04f8f 2023-07-19 thomas The former is only valid if invoked in a work tree, while the latter will
577 66b04f8f 2023-07-19 thomas resolve to the tip of the work tree's current branch if invoked in a
578 66b04f8f 2023-07-19 thomas work tree, otherwise it will resolve to the repository's HEAD reference.
579 66b04f8f 2023-07-19 thomas Keywords and references may be appended with
580 66b04f8f 2023-07-19 thomas .Qq :+
581 66b04f8f 2023-07-19 thomas or
582 66b04f8f 2023-07-19 thomas .Qq :-
583 66b04f8f 2023-07-19 thomas modifiers and an optional integer N to denote the
584 66b04f8f 2023-07-19 thomas Nth descendant or antecedent by first parent traversal, respectively;
585 66b04f8f 2023-07-19 thomas for example,
586 66b04f8f 2023-07-19 thomas .Sy :head:-2
587 66b04f8f 2023-07-19 thomas denotes the work tree branch head's 2nd generation ancestor, and
588 66b04f8f 2023-07-19 thomas .Sy :base:+4
589 66b04f8f 2023-07-19 thomas denotes the 4th generation descendant of the work tree's base commit.
590 66b04f8f 2023-07-19 thomas Similarly,
591 66b04f8f 2023-07-19 thomas .Sy foobar:+3
592 66b04f8f 2023-07-19 thomas will denote the 3rd generation descendant of the commit resolved by the
593 66b04f8f 2023-07-19 thomas .Qq foobar
594 66b04f8f 2023-07-19 thomas reference.
595 66b04f8f 2023-07-19 thomas A
596 66b04f8f 2023-07-19 thomas .Qq :+
597 66b04f8f 2023-07-19 thomas or
598 66b04f8f 2023-07-19 thomas .Qq :-
599 66b04f8f 2023-07-19 thomas modifier without a trailing integer has an implicit
600 66b04f8f 2023-07-19 thomas .Qq 1
601 66b04f8f 2023-07-19 thomas appended
602 66b04f8f 2023-07-19 thomas .Po e.g.,
603 66b04f8f 2023-07-19 thomas .Sy :base:+
604 66b04f8f 2023-07-19 thomas is equivalent to
605 66b04f8f 2023-07-19 thomas .Sy :base:+1
606 66b04f8f 2023-07-19 thomas .Pc .
607 69069811 2018-08-02 stsp .It Fl r Ar repository-path
608 69069811 2018-08-02 stsp Use the repository at the specified path.
609 69069811 2018-08-02 stsp If not specified, assume the repository is located at or above the current
610 69069811 2018-08-02 stsp working directory.
611 212b39d1 2020-02-24 naddy If this directory is a
612 212b39d1 2020-02-24 naddy .Xr got 1
613 212b39d1 2020-02-24 naddy work tree, use the repository path associated with this work tree.
614 030916b5 2018-07-12 stsp .El
615 56c96eff 2022-08-30 thomas .It Xo
616 56c96eff 2022-08-30 thomas .Cm tree
617 56c96eff 2022-08-30 thomas .Op Fl c Ar commit
618 56c96eff 2022-08-30 thomas .Op Fl r Ar repository-path
619 56c96eff 2022-08-30 thomas .Op Ar path
620 56c96eff 2022-08-30 thomas .Xc
621 030916b5 2018-07-12 stsp Display the repository tree.
622 55cccc34 2020-02-20 stsp If a
623 55cccc34 2020-02-20 stsp .Ar path
624 55cccc34 2020-02-20 stsp is specified, show tree entries at this path.
625 030916b5 2018-07-12 stsp .Pp
626 848d6979 2019-08-12 stsp Displayed tree entries may carry one of the following trailing annotations:
627 848d6979 2019-08-12 stsp .Bl -column YXZ description
628 848d6979 2019-08-12 stsp .It @ Ta entry is a symbolic link
629 848d6979 2019-08-12 stsp .It / Ta entry is a directory
630 848d6979 2019-08-12 stsp .It * Ta entry is an executable file
631 63c5ca5d 2019-08-24 stsp .It $ Ta entry is a Git submodule
632 848d6979 2019-08-12 stsp .El
633 0d6c6ee3 2020-05-20 stsp .Pp
634 0d6c6ee3 2020-05-20 stsp Symbolic link entries are also annotated with the target path of the link.
635 848d6979 2019-08-12 stsp .Pp
636 030916b5 2018-07-12 stsp The key bindings for
637 030916b5 2018-07-12 stsp .Cm tog tree
638 07b0611c 2022-06-23 thomas are as follows (N denotes optional prefixed count modifier):
639 030916b5 2018-07-12 stsp .Bl -tag -width Ds
640 f7140bf5 2021-10-17 thomas .It Cm Down-arrow, j, Ctrl-n
641 07b0611c 2022-06-23 thomas Move the selection cursor down N lines (default: 1).
642 f7140bf5 2021-10-17 thomas .It Cm Up-arrow, k, Ctrl-p
643 07b0611c 2022-06-23 thomas Move the selection cursor up N lines (default: 1).
644 4c2d69cb 2022-06-23 thomas .It Cm Page-down, Space, Ctrl+f, f
645 07b0611c 2022-06-23 thomas Move the selection cursor down N pages (default: 1).
646 1c5e5faa 2022-06-23 thomas .It Cm Page-up, Ctrl+b, b
647 07b0611c 2022-06-23 thomas Move the selection cursor up N pages (default: 1).
648 23427b14 2022-06-23 thomas .It Cm Ctrl+d, d
649 07b0611c 2022-06-23 thomas Move the selection cursor down N half pages (default: 1).
650 23427b14 2022-06-23 thomas .It Cm Ctrl+u, u
651 07b0611c 2022-06-23 thomas Move the selection cursor up N half pages (default: 1).
652 aa7a1117 2023-01-09 thomas .It Cm Home, =
653 e4526bf5 2021-09-03 naddy Move the selection cursor to the first entry.
654 aa7a1117 2023-01-09 thomas .It Cm End, *
655 e4526bf5 2021-09-03 naddy Move the selection cursor to the last entry.
656 aa7a1117 2023-01-09 thomas .It Cm g
657 aa7a1117 2023-01-09 thomas Move the selection cursor to entry N (default: 1).
658 aa7a1117 2023-01-09 thomas .It Cm G
659 aa7a1117 2023-01-09 thomas Like
660 aa7a1117 2023-01-09 thomas .Cm g
661 aa7a1117 2023-01-09 thomas but defaults to the last entry.
662 030916b5 2018-07-12 stsp .It Cm Enter
663 030916b5 2018-07-12 stsp Enter the currently selected directory, or switch to the
664 030916b5 2018-07-12 stsp .Cm blame
665 030916b5 2018-07-12 stsp view for the currently selected file.
666 1be4947a 2022-07-22 thomas .It Cm L
667 c0d30c23 2018-10-07 stsp Open a
668 69efd4c4 2018-07-18 stsp .Cm log
669 69efd4c4 2018-07-18 stsp view for the currently selected tree entry.
670 1be4947a 2022-07-22 thomas .It Cm R
671 152c1c93 2020-11-29 stsp Open a
672 152c1c93 2020-11-29 stsp .Cm ref
673 152c1c93 2020-11-29 stsp view listing all references in the repository.
674 152c1c93 2020-11-29 stsp This can then be used to open a new
675 152c1c93 2020-11-29 stsp .Cm tree
676 152c1c93 2020-11-29 stsp view for arbitrary branches and tags.
677 7837eeac 2018-09-24 stsp .It Cm Backspace
678 07b0611c 2022-06-23 thomas Move back to the Nth parent directory (default: 1).
679 030916b5 2018-07-12 stsp .It Cm i
680 c0d30c23 2018-10-07 stsp Show object IDs for all objects displayed in the
681 030916b5 2018-07-12 stsp .Cm tree
682 030916b5 2018-07-12 stsp view.
683 4eec20aa 2019-06-22 stsp .It Cm /
684 4eec20aa 2019-06-22 stsp Prompt for a search pattern and start searching for matching tree entries.
685 4eec20aa 2019-06-22 stsp The search pattern is an extended regular expression which is matched
686 4eec20aa 2019-06-22 stsp against the tree entry's name.
687 4eec20aa 2019-06-22 stsp Regular expression syntax is documented in
688 4eec20aa 2019-06-22 stsp .Xr re_format 7 .
689 4eec20aa 2019-06-22 stsp .It Cm n
690 07b0611c 2022-06-23 thomas Find the Nth next tree entry which matches the current search pattern
691 07b0611c 2022-06-23 thomas (default: 1).
692 4eec20aa 2019-06-22 stsp .It Cm N
693 07b0611c 2022-06-23 thomas Find the Nth previous tree entry which matches the current search pattern
694 07b0611c 2022-06-23 thomas (default: 1).
695 030916b5 2018-07-12 stsp .El
696 030916b5 2018-07-12 stsp .Pp
697 030916b5 2018-07-12 stsp The options for
698 030916b5 2018-07-12 stsp .Cm tog tree
699 030916b5 2018-07-12 stsp are as follows:
700 030916b5 2018-07-12 stsp .Bl -tag -width Ds
701 030916b5 2018-07-12 stsp .It Fl c Ar commit
702 030916b5 2018-07-12 stsp Start traversing history at the specified
703 030916b5 2018-07-12 stsp .Ar commit .
704 66b04f8f 2023-07-19 thomas The expected argument is a commit ID SHA1 hash, or a reference name or keyword
705 66b04f8f 2023-07-19 thomas which will be resolved to a commit ID.
706 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
707 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
708 66b04f8f 2023-07-19 thomas The keywords
709 66b04f8f 2023-07-19 thomas .Qq :base
710 66b04f8f 2023-07-19 thomas and
711 66b04f8f 2023-07-19 thomas .Qq :head
712 66b04f8f 2023-07-19 thomas resolve to the work tree's base commit and branch head, respectively.
713 66b04f8f 2023-07-19 thomas The former is only valid if invoked in a work tree, while the latter will
714 66b04f8f 2023-07-19 thomas resolve to the tip of the work tree's current branch if invoked in a
715 66b04f8f 2023-07-19 thomas work tree, otherwise it will resolve to the repository's HEAD reference.
716 66b04f8f 2023-07-19 thomas Keywords and references may be appended with
717 66b04f8f 2023-07-19 thomas .Qq :+
718 66b04f8f 2023-07-19 thomas or
719 66b04f8f 2023-07-19 thomas .Qq :-
720 66b04f8f 2023-07-19 thomas modifiers and an optional integer N to denote the
721 66b04f8f 2023-07-19 thomas Nth descendant or antecedent by first parent traversal, respectively;
722 66b04f8f 2023-07-19 thomas for example,
723 66b04f8f 2023-07-19 thomas .Sy :head:-2
724 66b04f8f 2023-07-19 thomas denotes the work tree branch head's 2nd generation ancestor, and
725 66b04f8f 2023-07-19 thomas .Sy :base:+4
726 66b04f8f 2023-07-19 thomas denotes the 4th generation descendant of the work tree's base commit.
727 66b04f8f 2023-07-19 thomas Similarly,
728 66b04f8f 2023-07-19 thomas .Sy foobar:+3
729 66b04f8f 2023-07-19 thomas will denote the 3rd generation descendant of the commit resolved by the
730 66b04f8f 2023-07-19 thomas .Qq foobar
731 66b04f8f 2023-07-19 thomas reference.
732 66b04f8f 2023-07-19 thomas A
733 66b04f8f 2023-07-19 thomas .Qq :+
734 66b04f8f 2023-07-19 thomas or
735 66b04f8f 2023-07-19 thomas .Qq :-
736 66b04f8f 2023-07-19 thomas modifier without a trailing integer has an implicit
737 66b04f8f 2023-07-19 thomas .Qq 1
738 66b04f8f 2023-07-19 thomas appended
739 66b04f8f 2023-07-19 thomas .Po e.g.,
740 66b04f8f 2023-07-19 thomas .Sy :base:+
741 66b04f8f 2023-07-19 thomas is equivalent to
742 66b04f8f 2023-07-19 thomas .Sy :base:+1
743 66b04f8f 2023-07-19 thomas .Pc .
744 38cb327b 2020-11-24 stsp .It Fl r Ar repository-path
745 38cb327b 2020-11-24 stsp Use the repository at the specified path.
746 38cb327b 2020-11-24 stsp If not specified, assume the repository is located at or above the current
747 38cb327b 2020-11-24 stsp working directory.
748 38cb327b 2020-11-24 stsp If this directory is a
749 38cb327b 2020-11-24 stsp .Xr got 1
750 38cb327b 2020-11-24 stsp work tree, use the repository path associated with this work tree.
751 38cb327b 2020-11-24 stsp .El
752 56c96eff 2022-08-30 thomas .It Cm ref Op Fl r Ar repository-path
753 38cb327b 2020-11-24 stsp Display references in the repository.
754 38cb327b 2020-11-24 stsp .Pp
755 38cb327b 2020-11-24 stsp The key bindings for
756 38cb327b 2020-11-24 stsp .Cm tog ref
757 07b0611c 2022-06-23 thomas are as follows (N denotes optional prefixed count modifier):
758 38cb327b 2020-11-24 stsp .Bl -tag -width Ds
759 f7140bf5 2021-10-17 thomas .It Cm Down-arrow, j, Ctrl-n
760 07b0611c 2022-06-23 thomas Move the selection cursor down N lines (default: 1).
761 f7140bf5 2021-10-17 thomas .It Cm Up-arrow, k, Ctrl-p
762 07b0611c 2022-06-23 thomas Move the selection cursor up N lines (default: 1).
763 4c2d69cb 2022-06-23 thomas .It Cm Page-down, Space, Ctrl+f, f
764 07b0611c 2022-06-23 thomas Move the selection cursor down N pages (default: 1).
765 1c5e5faa 2022-06-23 thomas .It Cm Page-up, Ctrl+b, b
766 07b0611c 2022-06-23 thomas Move the selection cursor up N pages (default: 1).
767 23427b14 2022-06-23 thomas .It Cm Ctrl+d, d
768 07b0611c 2022-06-23 thomas Move the selection cursor down N half pages (default: 1).
769 23427b14 2022-06-23 thomas .It Cm Ctrl+u, u
770 07b0611c 2022-06-23 thomas Move the selection cursor up N half pages (default: 1).
771 aa7a1117 2023-01-09 thomas .It Cm Home, =
772 e4526bf5 2021-09-03 naddy Move the selection cursor to the first reference.
773 aa7a1117 2023-01-09 thomas .It Cm End, *
774 e4526bf5 2021-09-03 naddy Move the selection cursor to the last reference.
775 aa7a1117 2023-01-09 thomas .It Cm g
776 aa7a1117 2023-01-09 thomas Move the selection cursor to reference N (default: 1).
777 aa7a1117 2023-01-09 thomas .It Cm G
778 aa7a1117 2023-01-09 thomas Like
779 aa7a1117 2023-01-09 thomas .Cm g
780 aa7a1117 2023-01-09 thomas but defaults to the last reference.
781 38cb327b 2020-11-24 stsp .It Cm Enter
782 01ca22b1 2020-12-07 stsp Open a
783 01ca22b1 2020-12-07 stsp .Cm log
784 01ca22b1 2020-12-07 stsp view which begins traversing history at the commit resolved via the
785 38cb327b 2020-11-24 stsp currently selected reference.
786 1be4947a 2022-07-22 thomas .It Cm T
787 c42c9805 2020-11-24 stsp Open a
788 c42c9805 2020-11-24 stsp .Cm tree
789 c42c9805 2020-11-24 stsp view showing the tree resolved via the currently selected reference.
790 38cb327b 2020-11-24 stsp .It Cm i
791 38cb327b 2020-11-24 stsp Show object IDs for all non-symbolic references displayed in the
792 38cb327b 2020-11-24 stsp .Cm ref
793 38cb327b 2020-11-24 stsp view.
794 84227eb1 2022-06-23 thomas .It Cm m
795 84227eb1 2022-06-23 thomas Show last modified date of each displayed reference.
796 98182bd0 2021-11-20 thomas .It Cm o
797 3bfadbd4 2021-11-20 thomas Toggle display order of references between sort by name and sort by timestamp.
798 38cb327b 2020-11-24 stsp .It Cm /
799 38cb327b 2020-11-24 stsp Prompt for a search pattern and start searching for matching references.
800 38cb327b 2020-11-24 stsp The search pattern is an extended regular expression which is matched
801 38cb327b 2020-11-24 stsp against absolute reference names.
802 38cb327b 2020-11-24 stsp Regular expression syntax is documented in
803 38cb327b 2020-11-24 stsp .Xr re_format 7 .
804 38cb327b 2020-11-24 stsp .It Cm n
805 07b0611c 2022-06-23 thomas Find the Nth next reference which matches the current search pattern
806 07b0611c 2022-06-23 thomas (default: 1).
807 38cb327b 2020-11-24 stsp .It Cm N
808 07b0611c 2022-06-23 thomas Find the Nth previous reference which matches the current search pattern
809 07b0611c 2022-06-23 thomas (default: 1).
810 38cb327b 2020-11-24 stsp .It Cm Ctrl+l
811 38cb327b 2020-11-24 stsp Reload the list of references displayed by the
812 38cb327b 2020-11-24 stsp .Cm ref
813 38cb327b 2020-11-24 stsp view.
814 38cb327b 2020-11-24 stsp .El
815 38cb327b 2020-11-24 stsp .Pp
816 38cb327b 2020-11-24 stsp The options for
817 38cb327b 2020-11-24 stsp .Cm tog ref
818 38cb327b 2020-11-24 stsp are as follows:
819 38cb327b 2020-11-24 stsp .Bl -tag -width Ds
820 74283ab8 2020-02-07 stsp .It Fl r Ar repository-path
821 74283ab8 2020-02-07 stsp Use the repository at the specified path.
822 74283ab8 2020-02-07 stsp If not specified, assume the repository is located at or above the current
823 74283ab8 2020-02-07 stsp working directory.
824 74283ab8 2020-02-07 stsp If this directory is a
825 74283ab8 2020-02-07 stsp .Xr got 1
826 74283ab8 2020-02-07 stsp work tree, use the repository path associated with this work tree.
827 030916b5 2018-07-12 stsp .El
828 030916b5 2018-07-12 stsp .El
829 6d17833f 2019-11-08 stsp .Sh ENVIRONMENT
830 64486692 2022-07-07 thomas .Bl -tag -width TOG_VIEW_SPLIT_MODE
831 6d17833f 2019-11-08 stsp .It Ev TOG_COLORS
832 6d17833f 2019-11-08 stsp .Nm
833 6d17833f 2019-11-08 stsp shows colorized output if this variable is set to a non-empty value.
834 6d17833f 2019-11-08 stsp The default color scheme can be modified by setting the environment
835 6d17833f 2019-11-08 stsp variables documented below.
836 6d17833f 2019-11-08 stsp The colors available in color schemes are
837 6d17833f 2019-11-08 stsp .Dq black ,
838 6d17833f 2019-11-08 stsp .Dq red ,
839 6d17833f 2019-11-08 stsp .Dq green ,
840 6d17833f 2019-11-08 stsp .Dq yellow ,
841 6d17833f 2019-11-08 stsp .Dq blue ,
842 93a300b2 2021-08-26 stsp .Dq magenta ,
843 1d7fe5cd 2019-11-08 stsp .Dq cyan ,
844 6d17833f 2019-11-08 stsp and
845 1d7fe5cd 2019-11-08 stsp .Dq default
846 1d7fe5cd 2019-11-08 stsp which maps to the terminal's default foreground color.
847 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_AUTHOR
848 bd15e874 2023-01-20 thomas The color used to mark up author information.
849 6d17833f 2019-11-08 stsp If not set, the default value
850 bd15e874 2023-01-20 thomas .Dq cyan
851 6d17833f 2019-11-08 stsp is used.
852 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_COMMIT
853 bd15e874 2023-01-20 thomas The color used to mark up commit IDs.
854 6d17833f 2019-11-08 stsp If not set, the default value
855 bd15e874 2023-01-20 thomas .Dq green
856 6d17833f 2019-11-08 stsp is used.
857 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_DATE
858 bd15e874 2023-01-20 thomas The color used to mark up date information.
859 bd15e874 2023-01-20 thomas If not set, the default value
860 bd15e874 2023-01-20 thomas .Dq yellow
861 bd15e874 2023-01-20 thomas is used.
862 6d17833f 2019-11-08 stsp .It Ev TOG_COLOR_DIFF_CHUNK_HEADER
863 6d17833f 2019-11-08 stsp The color used to mark up chunk header lines in diffs.
864 6d17833f 2019-11-08 stsp If not set, the default value
865 6d17833f 2019-11-08 stsp .Dq yellow
866 6d17833f 2019-11-08 stsp is used.
867 6d17833f 2019-11-08 stsp .It Ev TOG_COLOR_DIFF_META
868 6d17833f 2019-11-08 stsp The color used to mark up meta data in diffs.
869 c0b01bdb 2019-11-08 stsp If not set, the default value
870 c0b01bdb 2019-11-08 stsp .Dq green
871 c0b01bdb 2019-11-08 stsp is used.
872 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_DIFF_MINUS
873 bd15e874 2023-01-20 thomas The color used to mark up removed lines in diffs.
874 c0b01bdb 2019-11-08 stsp If not set, the default value
875 c0b01bdb 2019-11-08 stsp .Dq magenta
876 c0b01bdb 2019-11-08 stsp is used.
877 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_DIFF_PLUS
878 bd15e874 2023-01-20 thomas The color used to mark up added lines in diffs.
879 c0b01bdb 2019-11-08 stsp If not set, the default value
880 91b8c405 2020-01-25 stsp .Dq cyan
881 c0b01bdb 2019-11-08 stsp is used.
882 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_REFS_BACKUP
883 bd15e874 2023-01-20 thomas The color used to mark up references in the
884 bd15e874 2023-01-20 thomas .Dq refs/got/backup/
885 bd15e874 2023-01-20 thomas namespace.
886 11b20872 2019-11-08 stsp If not set, the default value
887 11b20872 2019-11-08 stsp .Dq cyan
888 11b20872 2019-11-08 stsp is used.
889 38cb327b 2020-11-24 stsp .It Ev TOG_COLOR_REFS_HEADS
890 38cb327b 2020-11-24 stsp The color used to mark up references in the
891 38cb327b 2020-11-24 stsp .Dq refs/heads/
892 38cb327b 2020-11-24 stsp namespace.
893 38cb327b 2020-11-24 stsp If not set, the default value
894 38cb327b 2020-11-24 stsp .Dq green
895 38cb327b 2020-11-24 stsp is used.
896 38cb327b 2020-11-24 stsp .It Ev TOG_COLOR_REFS_REMOTES
897 38cb327b 2020-11-24 stsp The color used to mark up references in the
898 38cb327b 2020-11-24 stsp .Dq refs/remotes/
899 38cb327b 2020-11-24 stsp namespace.
900 38cb327b 2020-11-24 stsp If not set, the default value
901 38cb327b 2020-11-24 stsp .Dq yellow
902 38cb327b 2020-11-24 stsp is used.
903 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_REFS_TAGS
904 2183bbf6 2022-01-23 thomas The color used to mark up references in the
905 bd15e874 2023-01-20 thomas .Dq refs/tags/
906 2183bbf6 2022-01-23 thomas namespace.
907 2183bbf6 2022-01-23 thomas If not set, the default value
908 bd15e874 2023-01-20 thomas .Dq magenta
909 bd15e874 2023-01-20 thomas is used.
910 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_TREE_DIRECTORY
911 bd15e874 2023-01-20 thomas The color used to mark up directory tree entries.
912 bd15e874 2023-01-20 thomas If not set, the default value
913 2183bbf6 2022-01-23 thomas .Dq cyan
914 2183bbf6 2022-01-23 thomas is used.
915 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_TREE_EXECUTABLE
916 bd15e874 2023-01-20 thomas The color used to mark up executable file tree entries.
917 bd15e874 2023-01-20 thomas If not set, the default value
918 bd15e874 2023-01-20 thomas .Dq green
919 bd15e874 2023-01-20 thomas is used.
920 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_TREE_SUBMODULE
921 bd15e874 2023-01-20 thomas The color used to mark up submodule tree entries.
922 bd15e874 2023-01-20 thomas If not set, the default value
923 bd15e874 2023-01-20 thomas .Dq magenta
924 bd15e874 2023-01-20 thomas is used.
925 bd15e874 2023-01-20 thomas .It Ev TOG_COLOR_TREE_SYMLINK
926 bd15e874 2023-01-20 thomas The color used to mark up symbolic link tree entries.
927 bd15e874 2023-01-20 thomas If not set, the default value
928 bd15e874 2023-01-20 thomas .Dq magenta
929 bd15e874 2023-01-20 thomas is used.
930 bd15e874 2023-01-20 thomas .It Ev TOG_DIFF_ALGORITHM
931 bd15e874 2023-01-20 thomas Determines the default diff algorithm used by
932 bd15e874 2023-01-20 thomas .Nm .
933 bd15e874 2023-01-20 thomas Supported diff algorithms are Myers (quick and dirty) and
934 bd15e874 2023-01-20 thomas Patience (slow and tidy).
935 bd15e874 2023-01-20 thomas Valid values for
936 bd15e874 2023-01-20 thomas .Ev TOG_DIFF_ALGORITHM
937 bd15e874 2023-01-20 thomas are
938 bd15e874 2023-01-20 thomas .Dq patience
939 bd15e874 2023-01-20 thomas and
940 bd15e874 2023-01-20 thomas .Dq myers .
941 8295dece 2023-10-08 thomas If unset, the Patience diff algorithm will be used by default.
942 bd15e874 2023-01-20 thomas .It Ev TOG_VIEW_SPLIT_MODE
943 bd15e874 2023-01-20 thomas Determines the default layout of split-screen views.
944 bd15e874 2023-01-20 thomas If set to
945 bd15e874 2023-01-20 thomas .Dq h
946 bd15e874 2023-01-20 thomas or
947 bd15e874 2023-01-20 thomas .Dq H ,
948 bd15e874 2023-01-20 thomas .Nm
949 bd15e874 2023-01-20 thomas will use horizontal split by default.
950 bd15e874 2023-01-20 thomas Otherwise, vertical split will be used.
951 bd15e874 2023-01-20 thomas The
952 bd15e874 2023-01-20 thomas .Cm S
953 bd15e874 2023-01-20 thomas key can be used to switch between vertical and horizontal split layout
954 bd15e874 2023-01-20 thomas at run-time.
955 6d17833f 2019-11-08 stsp .El
956 030916b5 2018-07-12 stsp .Sh EXIT STATUS
957 030916b5 2018-07-12 stsp .Ex -std tog
958 030916b5 2018-07-12 stsp .Sh SEE ALSO
959 56b9a4ca 2019-06-21 stsp .Xr got 1 ,
960 56b9a4ca 2019-06-21 stsp .Xr git-repository 5 ,
961 56b9a4ca 2019-06-21 stsp .Xr re_format 7
962 030916b5 2018-07-12 stsp .Sh AUTHORS
963 60c73080 2022-07-05 thomas .An Christian Weisgerber Aq Mt naddy@openbsd.org
964 60c73080 2022-07-05 thomas .An Josh Rickmar Aq Mt jrick@zettaport.com
965 bc3056e3 2019-08-18 stsp .An Joshua Stein Aq Mt jcs@openbsd.org
966 60c73080 2022-07-05 thomas .An Mark Jamsek Aq Mt mark@jamsek.dev
967 60c73080 2022-07-05 thomas .An Martin Pieuchot Aq Mt mpi@openbsd.org
968 60c73080 2022-07-05 thomas .An Omar Polo Aq Mt op@openbsd.org
969 60c73080 2022-07-05 thomas .An Stefan Sperling Aq Mt stsp@openbsd.org
970 60c73080 2022-07-05 thomas .An Klemens Nanni Aq Mt kn@openbsd.org