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 030916b5 2018-07-12 stsp .Nd git repository browser
22 030916b5 2018-07-12 stsp .Sh SYNOPSIS
23 030916b5 2018-07-12 stsp .Nm
24 030916b5 2018-07-12 stsp .Ar command
25 030916b5 2018-07-12 stsp .Op Fl h
26 030916b5 2018-07-12 stsp .Op Ar arg ...
27 030916b5 2018-07-12 stsp .Sh DESCRIPTION
28 030916b5 2018-07-12 stsp .Nm
29 030916b5 2018-07-12 stsp is an interactive read-only browser for git repositories.
30 030916b5 2018-07-12 stsp This repository format is described in
31 5e5560e1 2018-08-01 stsp .Xr git-repository 5 .
32 030916b5 2018-07-12 stsp .Pp
33 030916b5 2018-07-12 stsp .Nm
34 0cf4efb1 2018-09-29 stsp supports several types of views which display repository data:
35 87aa0e98 2018-08-18 stsp .Bl -tag -width Ds
36 9419758a 2019-03-27 stsp .It Log view
37 87aa0e98 2018-08-18 stsp Displays commits in the repository's history.
38 87aa0e98 2018-08-18 stsp This view is displayed initially if no
39 87aa0e98 2018-08-18 stsp .Ar command
40 87aa0e98 2018-08-18 stsp is specified.
41 9419758a 2019-03-27 stsp .It Diff view
42 87aa0e98 2018-08-18 stsp Displays changes made in a particular commit.
43 9419758a 2019-03-27 stsp .It Blame view
44 87aa0e98 2018-08-18 stsp Displays the line-by-line history of a file.
45 9419758a 2019-03-27 stsp .It Tree view
46 87aa0e98 2018-08-18 stsp Displays the tree corresponding to a particular commit.
47 87aa0e98 2018-08-18 stsp .El
48 87aa0e98 2018-08-18 stsp .Pp
49 87aa0e98 2018-08-18 stsp .Nm
50 87aa0e98 2018-08-18 stsp provides global and command-specific key bindings and options.
51 87aa0e98 2018-08-18 stsp The global key bindings are:
52 87aa0e98 2018-08-18 stsp .Bl -tag -width Ds
53 87aa0e98 2018-08-18 stsp .It Cm Q
54 87aa0e98 2018-08-18 stsp Quit
55 87aa0e98 2018-08-18 stsp .Nm .
56 87aa0e98 2018-08-18 stsp .It Cm q
57 87aa0e98 2018-08-18 stsp Quit the view which is in focus.
58 87aa0e98 2018-08-18 stsp .It Cm Tab
59 c0d30c23 2018-10-07 stsp Switch focus between views.
60 0cf4efb1 2018-09-29 stsp .It Cm f
61 c0d30c23 2018-10-07 stsp Toggle fullscreen mode for a split-screen view.
62 e9b3576f 2019-03-27 stsp .Nm
63 e9b3576f 2019-03-27 stsp will automatically use split-screen views if the size of the terminal
64 e9b3576f 2019-03-27 stsp window is sufficiently large.
65 87aa0e98 2018-08-18 stsp .El
66 87aa0e98 2018-08-18 stsp .Pp
67 87aa0e98 2018-08-18 stsp Global options must precede the command name, and are as follows:
68 030916b5 2018-07-12 stsp .Bl -tag -width tenletters
69 030916b5 2018-07-12 stsp .It Fl h
70 030916b5 2018-07-12 stsp Display usage information.
71 030916b5 2018-07-12 stsp .El
72 030916b5 2018-07-12 stsp .Pp
73 030916b5 2018-07-12 stsp The commands for
74 030916b5 2018-07-12 stsp .Nm
75 030916b5 2018-07-12 stsp are as follows:
76 030916b5 2018-07-12 stsp .Bl -tag -width blame
77 ecb28ae0 2018-07-16 stsp .It Cm log [ Fl c Ar commit ] [ Fl r Ar repository-path ] [ path ]
78 030916b5 2018-07-12 stsp Display history of a repository.
79 ecb28ae0 2018-07-16 stsp If a
80 ecb28ae0 2018-07-16 stsp .Ar path
81 ecb28ae0 2018-07-16 stsp is specified, show only commits which modified this path.
82 030916b5 2018-07-12 stsp .Pp
83 030916b5 2018-07-12 stsp This command is also executed if no explicit command is specified.
84 030916b5 2018-07-12 stsp .Pp
85 030916b5 2018-07-12 stsp The key bindings for
86 030916b5 2018-07-12 stsp .Cm tog log
87 030916b5 2018-07-12 stsp are as follows:
88 030916b5 2018-07-12 stsp .Bl -tag -width Ds
89 eb029fd6 2019-05-13 stsp .It Cm Down-arrow, j, >, Full stop
90 030916b5 2018-07-12 stsp Move the selection cursor down.
91 eb029fd6 2019-05-13 stsp .It Cm Up-arrow, k, <, Comma
92 030916b5 2018-07-12 stsp Move the selection cursor up.
93 9be75582 2019-06-26 stsp .It Cm Page-down, Ctrl+f
94 a60a9dc4 2019-05-13 jcs Move the selection cursor down one page.
95 9be75582 2019-06-26 stsp .It Cm Page-up, Ctrl+b
96 a60a9dc4 2019-05-13 jcs Move the selection cursor up one page.
97 e350feed 2019-05-12 stsp .It Cm Enter, Space
98 c0d30c23 2018-10-07 stsp Open a
99 030916b5 2018-07-12 stsp .Cm diff
100 030916b5 2018-07-12 stsp view showing file changes made in the currently selected commit.
101 030916b5 2018-07-12 stsp .It Cm t
102 a60a9dc4 2019-05-13 jcs Open a
103 030916b5 2018-07-12 stsp .Cm tree
104 030916b5 2018-07-12 stsp view showing the tree for the currently selected commit.
105 5036bf37 2018-09-24 stsp .It Cm Backspace
106 5036bf37 2018-09-24 stsp Show log entries for the parent directory of the currently selected path.
107 60493ae3 2019-06-20 stsp .It Cm /
108 60493ae3 2019-06-20 stsp Prompt for a search pattern and start searching for matching commits.
109 60493ae3 2019-06-20 stsp The search pattern is an extended regular expression which is matched
110 df0b3d8a 2019-06-28 stsp against a commit's author name, committer name, log message, and
111 df0b3d8a 2019-06-28 stsp commit ID SHA1 hash.
112 e6c76b79 2019-06-21 stsp Regular expression syntax is documented in
113 e6c76b79 2019-06-21 stsp .Xr re_format 7 .
114 60493ae3 2019-06-20 stsp .It Cm n
115 60493ae3 2019-06-20 stsp Find the next commit which matches the current search pattern.
116 b1bf1435 2019-06-21 stsp .It Cm N
117 b1bf1435 2019-06-21 stsp Find the previous commit which matches the current search pattern.
118 bf0668dd 2019-06-26 stsp .It Cm Ctrl+l
119 d01904d4 2019-06-25 stsp Reload the log view with new commits found in the repository.
120 030916b5 2018-07-12 stsp .El
121 030916b5 2018-07-12 stsp .Pp
122 030916b5 2018-07-12 stsp The options for
123 030916b5 2018-07-12 stsp .Cm tog log
124 030916b5 2018-07-12 stsp are as follows:
125 030916b5 2018-07-12 stsp .Bl -tag -width Ds
126 030916b5 2018-07-12 stsp .It Fl c Ar commit
127 030916b5 2018-07-12 stsp Start traversing history at the specified
128 030916b5 2018-07-12 stsp .Ar commit .
129 a54b6686 2019-06-28 stsp The expected argument is the name of a branch or a commit ID SHA1 hash.
130 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
131 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
132 19e70ad6 2019-05-14 stsp If this option is not specified, default to the work tree's current branch
133 19e70ad6 2019-05-14 stsp if invoked in a work tree, or to the repository's HEAD reference.
134 ecb28ae0 2018-07-16 stsp .It Fl r Ar repository-path
135 ecb28ae0 2018-07-16 stsp Use the repository at the specified path.
136 ecb28ae0 2018-07-16 stsp If not specified, assume the repository is located at or above the current
137 ecb28ae0 2018-07-16 stsp working directory.
138 030916b5 2018-07-12 stsp .El
139 030916b5 2018-07-12 stsp .It Cm diff [ Ar repository-path ] Ar object1 Ar object2
140 030916b5 2018-07-12 stsp Display the differences between two objects in the repository.
141 030916b5 2018-07-12 stsp Each
142 030916b5 2018-07-12 stsp .Ar object
143 a54b6686 2019-06-28 stsp argument is an object ID SHA1 hash.
144 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
145 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
146 030916b5 2018-07-12 stsp Both objects must be of the same type (blobs, trees, or commits).
147 030916b5 2018-07-12 stsp If the
148 030916b5 2018-07-12 stsp .Ar repository path
149 030916b5 2018-07-12 stsp is omitted, use the current working directory.
150 030916b5 2018-07-12 stsp .Pp
151 030916b5 2018-07-12 stsp The key bindings for
152 030916b5 2018-07-12 stsp .Cm tog diff
153 030916b5 2018-07-12 stsp are as follows:
154 030916b5 2018-07-12 stsp .Bl -tag -width Ds
155 a60a9dc4 2019-05-13 jcs .It Cm Down-arrow, j
156 030916b5 2018-07-12 stsp Scroll down.
157 eb029fd6 2019-05-13 stsp .It Cm Up-arrow, k
158 030916b5 2018-07-12 stsp Scroll up.
159 a60a9dc4 2019-05-13 jcs .It Cm Page-down, Space, Ctrl+f
160 a60a9dc4 2019-05-13 jcs Scroll down one page.
161 a60a9dc4 2019-05-13 jcs .It Cm Page-up, Ctrl+b
162 a60a9dc4 2019-05-13 jcs Scroll up one page.
163 48ae06ee 2018-10-18 stsp .It Cm [
164 48ae06ee 2018-10-18 stsp Reduce the amount of diff context lines.
165 48ae06ee 2018-10-18 stsp .It Cm ]
166 48ae06ee 2018-10-18 stsp Increase the amount of diff context lines.
167 15a087fe 2019-02-21 stsp .It Cm <, Comma
168 15a087fe 2019-02-21 stsp If the diff view was opened via the log view, move to the previous (younger)
169 15a087fe 2019-02-21 stsp commit.
170 15a087fe 2019-02-21 stsp .It Cm >, Full stop
171 15a087fe 2019-02-21 stsp If the diff view was opened via the log view, move to the next (older) commit.
172 030916b5 2018-07-12 stsp .El
173 69069811 2018-08-02 stsp .It Cm blame [ Fl c Ar commit ] [ Fl r Ar repository-path ] Ar path
174 030916b5 2018-07-12 stsp Display line-by-line history of a file at the specified path.
175 030916b5 2018-07-12 stsp .Pp
176 030916b5 2018-07-12 stsp The key bindings for
177 030916b5 2018-07-12 stsp .Cm tog blame
178 030916b5 2018-07-12 stsp are as follows:
179 030916b5 2018-07-12 stsp .Bl -tag -width Ds
180 38f94530 2018-07-12 stsp .It Cm Down-arrow, j, Page-down, Space
181 030916b5 2018-07-12 stsp Move the selection cursor down.
182 31607d6c 2018-08-18 stsp .It Cm Up-arrow, k, Page-up
183 030916b5 2018-07-12 stsp Move the selection cursor up.
184 030916b5 2018-07-12 stsp .It Cm Enter
185 c0d30c23 2018-10-07 stsp Open a
186 030916b5 2018-07-12 stsp .Cm diff
187 030916b5 2018-07-12 stsp view for the currently selected line's commit.
188 030916b5 2018-07-12 stsp .It Cm b
189 c0d30c23 2018-10-07 stsp Reload the
190 030916b5 2018-07-12 stsp .Cm blame
191 c0d30c23 2018-10-07 stsp view with the version of the file as found in the currently
192 c0d30c23 2018-10-07 stsp selected line's commit.
193 7a2921f9 2018-07-12 stsp .It Cm p
194 c0d30c23 2018-10-07 stsp Reload the
195 7a2921f9 2018-07-12 stsp .Cm blame
196 c0d30c23 2018-10-07 stsp view with the version of the file as found in the parent commit of the
197 c0d30c23 2018-10-07 stsp currently selected line's commit.
198 030916b5 2018-07-12 stsp .It Cm B
199 c0d30c23 2018-10-07 stsp Reload the
200 030916b5 2018-07-12 stsp .Cm blame
201 c0d30c23 2018-10-07 stsp view with the previously blamed commit.
202 6c4c42e0 2019-06-24 stsp .It Cm /
203 6c4c42e0 2019-06-24 stsp Prompt for a search pattern and start searching for matching line.
204 6c4c42e0 2019-06-24 stsp The search pattern is an extended regular expression.
205 6c4c42e0 2019-06-24 stsp Regular expression syntax is documented in
206 6c4c42e0 2019-06-24 stsp .Xr re_format 7 .
207 6c4c42e0 2019-06-24 stsp .It Cm n
208 6c4c42e0 2019-06-24 stsp Find the next line which matches the current search pattern.
209 6c4c42e0 2019-06-24 stsp .It Cm N
210 6c4c42e0 2019-06-24 stsp Find the previous line which matches the current search pattern.
211 030916b5 2018-07-12 stsp .El
212 030916b5 2018-07-12 stsp .Pp
213 030916b5 2018-07-12 stsp The options for
214 030916b5 2018-07-12 stsp .Cm tog blame
215 030916b5 2018-07-12 stsp are as follows:
216 030916b5 2018-07-12 stsp .Bl -tag -width Ds
217 030916b5 2018-07-12 stsp .It Fl c Ar commit
218 030916b5 2018-07-12 stsp Start traversing history at the specified
219 030916b5 2018-07-12 stsp .Ar commit .
220 a54b6686 2019-06-28 stsp The expected argument is the name of a branch or a commit ID SHA1 hash.
221 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
222 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
223 69069811 2018-08-02 stsp .It Fl r Ar repository-path
224 69069811 2018-08-02 stsp Use the repository at the specified path.
225 69069811 2018-08-02 stsp If not specified, assume the repository is located at or above the current
226 69069811 2018-08-02 stsp working directory.
227 030916b5 2018-07-12 stsp .El
228 030916b5 2018-07-12 stsp .It Cm tree [ Fl c Ar commit ] [ Ar repository-path ]
229 030916b5 2018-07-12 stsp Display the repository tree.
230 030916b5 2018-07-12 stsp If the
231 030916b5 2018-07-12 stsp .Ar repository path
232 030916b5 2018-07-12 stsp is omitted, assume the repository is located in the current working directory.
233 030916b5 2018-07-12 stsp .Pp
234 030916b5 2018-07-12 stsp The key bindings for
235 030916b5 2018-07-12 stsp .Cm tog tree
236 030916b5 2018-07-12 stsp are as follows:
237 030916b5 2018-07-12 stsp .Bl -tag -width Ds
238 030916b5 2018-07-12 stsp .It Cm Down-arrow, j, Page-down
239 030916b5 2018-07-12 stsp Move the selection cursor down.
240 030916b5 2018-07-12 stsp .It Cm Up-arrow, k, Page-up
241 030916b5 2018-07-12 stsp Move the selection cursor up.
242 030916b5 2018-07-12 stsp .It Cm Enter
243 030916b5 2018-07-12 stsp Enter the currently selected directory, or switch to the
244 030916b5 2018-07-12 stsp .Cm blame
245 030916b5 2018-07-12 stsp view for the currently selected file.
246 69efd4c4 2018-07-18 stsp .It Cm l
247 c0d30c23 2018-10-07 stsp Open a
248 69efd4c4 2018-07-18 stsp .Cm log
249 69efd4c4 2018-07-18 stsp view for the currently selected tree entry.
250 7837eeac 2018-09-24 stsp .It Cm Backspace
251 030916b5 2018-07-12 stsp Move back to the parent directory.
252 030916b5 2018-07-12 stsp .It Cm i
253 c0d30c23 2018-10-07 stsp Show object IDs for all objects displayed in the
254 030916b5 2018-07-12 stsp .Cm tree
255 030916b5 2018-07-12 stsp view.
256 4eec20aa 2019-06-22 stsp .It Cm /
257 4eec20aa 2019-06-22 stsp Prompt for a search pattern and start searching for matching tree entries.
258 4eec20aa 2019-06-22 stsp The search pattern is an extended regular expression which is matched
259 4eec20aa 2019-06-22 stsp against the tree entry's name.
260 4eec20aa 2019-06-22 stsp Regular expression syntax is documented in
261 4eec20aa 2019-06-22 stsp .Xr re_format 7 .
262 4eec20aa 2019-06-22 stsp .It Cm n
263 4eec20aa 2019-06-22 stsp Find the next tree entry which matches the current search pattern.
264 4eec20aa 2019-06-22 stsp .It Cm N
265 4eec20aa 2019-06-22 stsp Find the previous tree entry which matches the current search pattern.
266 030916b5 2018-07-12 stsp .El
267 030916b5 2018-07-12 stsp .Pp
268 030916b5 2018-07-12 stsp The options for
269 030916b5 2018-07-12 stsp .Cm tog tree
270 030916b5 2018-07-12 stsp are as follows:
271 030916b5 2018-07-12 stsp .Bl -tag -width Ds
272 030916b5 2018-07-12 stsp .It Fl c Ar commit
273 030916b5 2018-07-12 stsp Start traversing history at the specified
274 030916b5 2018-07-12 stsp .Ar commit .
275 a54b6686 2019-06-28 stsp The expected argument is the name of a branch or a commit ID SHA1 hash.
276 0db75f06 2019-07-07 stsp An abbreviated hash argument will be expanded to a full SHA1 hash
277 0db75f06 2019-07-07 stsp automatically, provided the abbreviation is unique.
278 030916b5 2018-07-12 stsp .El
279 030916b5 2018-07-12 stsp .El
280 030916b5 2018-07-12 stsp .Sh EXIT STATUS
281 030916b5 2018-07-12 stsp .Ex -std tog
282 030916b5 2018-07-12 stsp .Sh SEE ALSO
283 56b9a4ca 2019-06-21 stsp .Xr got 1 ,
284 56b9a4ca 2019-06-21 stsp .Xr git-repository 5 ,
285 56b9a4ca 2019-06-21 stsp .Xr re_format 7
286 030916b5 2018-07-12 stsp .Sh AUTHORS
287 030916b5 2018-07-12 stsp .An Stefan Sperling Aq Mt stsp@openbsd.org
288 72e28b48 2019-05-14 stsp .An joshua stein Aq Mt jcs@openbsd.org