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 87aa0e98 2018-08-18 stsp supports several types of views which display repository data.
35 87aa0e98 2018-08-18 stsp An arbitrary number of views may be opened simultaneously by
36 87aa0e98 2018-08-18 stsp navigating the repository with
37 87aa0e98 2018-08-18 stsp .Nm .
38 bcbd79e2 2018-08-19 stsp Sometimes, if one view is opened from another view, the child view
39 bcbd79e2 2018-08-19 stsp is linked to its parent view and both views will keep their data
40 bcbd79e2 2018-08-19 stsp display in sync.
41 87aa0e98 2018-08-18 stsp The supported views are:
42 87aa0e98 2018-08-18 stsp .Bl -tag -width Ds
43 87aa0e98 2018-08-18 stsp .It Cm log view
44 87aa0e98 2018-08-18 stsp Displays commits in the repository's history.
45 87aa0e98 2018-08-18 stsp This view is displayed initially if no
46 87aa0e98 2018-08-18 stsp .Ar command
47 87aa0e98 2018-08-18 stsp is specified.
48 87aa0e98 2018-08-18 stsp .It Cm diff view
49 87aa0e98 2018-08-18 stsp Displays changes made in a particular commit.
50 87aa0e98 2018-08-18 stsp .It Cm blame view
51 87aa0e98 2018-08-18 stsp Displays the line-by-line history of a file.
52 87aa0e98 2018-08-18 stsp .It Cm tree view
53 87aa0e98 2018-08-18 stsp Displays the tree corresponding to a particular commit.
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 87aa0e98 2018-08-18 stsp The global key bindings are:
59 87aa0e98 2018-08-18 stsp .Bl -tag -width Ds
60 87aa0e98 2018-08-18 stsp .It Cm Q
61 87aa0e98 2018-08-18 stsp Quit
62 87aa0e98 2018-08-18 stsp .Nm .
63 87aa0e98 2018-08-18 stsp .It Cm q
64 87aa0e98 2018-08-18 stsp Quit the view which is in focus.
65 87aa0e98 2018-08-18 stsp .It Cm Tab
66 87aa0e98 2018-08-18 stsp Switch focus to the next view.
67 87aa0e98 2018-08-18 stsp Cycles through all open views.
68 38ce06e0 2018-09-24 stsp .It Cm ~
69 31607d6c 2018-08-18 stsp Switch focus to the previous view.
70 31607d6c 2018-08-18 stsp Cycles through all open views.
71 87aa0e98 2018-08-18 stsp .El
72 87aa0e98 2018-08-18 stsp .Pp
73 87aa0e98 2018-08-18 stsp Global options must precede the command name, and are as follows:
74 030916b5 2018-07-12 stsp .Bl -tag -width tenletters
75 030916b5 2018-07-12 stsp .It Fl h
76 030916b5 2018-07-12 stsp Display usage information.
77 030916b5 2018-07-12 stsp .El
78 030916b5 2018-07-12 stsp .Pp
79 030916b5 2018-07-12 stsp The commands for
80 030916b5 2018-07-12 stsp .Nm
81 030916b5 2018-07-12 stsp are as follows:
82 030916b5 2018-07-12 stsp .Bl -tag -width blame
83 ecb28ae0 2018-07-16 stsp .It Cm log [ Fl c Ar commit ] [ Fl r Ar repository-path ] [ path ]
84 030916b5 2018-07-12 stsp Display history of a repository.
85 ecb28ae0 2018-07-16 stsp If a
86 ecb28ae0 2018-07-16 stsp .Ar path
87 ecb28ae0 2018-07-16 stsp is specified, show only commits which modified this path.
88 030916b5 2018-07-12 stsp .Pp
89 030916b5 2018-07-12 stsp This command is also executed if no explicit command is specified.
90 030916b5 2018-07-12 stsp .Pp
91 030916b5 2018-07-12 stsp The key bindings for
92 030916b5 2018-07-12 stsp .Cm tog log
93 030916b5 2018-07-12 stsp are as follows:
94 030916b5 2018-07-12 stsp .Bl -tag -width Ds
95 bcbd79e2 2018-08-19 stsp .It Cm Down-arrow, j, ], Page-down
96 030916b5 2018-07-12 stsp Move the selection cursor down.
97 bcbd79e2 2018-08-19 stsp .It Cm Up-arrow, k, [, Page-up
98 030916b5 2018-07-12 stsp Move the selection cursor up.
99 030916b5 2018-07-12 stsp .It Cm Enter
100 030916b5 2018-07-12 stsp Switch to the
101 030916b5 2018-07-12 stsp .Cm diff
102 030916b5 2018-07-12 stsp view showing file changes made in the currently selected commit.
103 bcbd79e2 2018-08-19 stsp The diff view is linked to the log view so either view will be
104 bcbd79e2 2018-08-19 stsp updated when the other switches to a different commit.
105 030916b5 2018-07-12 stsp .It Cm t
106 030916b5 2018-07-12 stsp Switch to the
107 030916b5 2018-07-12 stsp .Cm tree
108 030916b5 2018-07-12 stsp view showing the tree for the currently selected commit.
109 5036bf37 2018-09-24 stsp .It Cm Backspace
110 5036bf37 2018-09-24 stsp Show log entries for the parent directory of the currently selected path.
111 030916b5 2018-07-12 stsp .El
112 030916b5 2018-07-12 stsp .Pp
113 030916b5 2018-07-12 stsp The options for
114 030916b5 2018-07-12 stsp .Cm tog log
115 030916b5 2018-07-12 stsp are as follows:
116 030916b5 2018-07-12 stsp .Bl -tag -width Ds
117 030916b5 2018-07-12 stsp .It Fl c Ar commit
118 030916b5 2018-07-12 stsp Start traversing history at the specified
119 030916b5 2018-07-12 stsp .Ar commit .
120 030916b5 2018-07-12 stsp The expected argument is the name of a branch or a SHA1 hash which corresponds
121 030916b5 2018-07-12 stsp to a commit object.
122 ecb28ae0 2018-07-16 stsp .It Fl r Ar repository-path
123 ecb28ae0 2018-07-16 stsp Use the repository at the specified path.
124 ecb28ae0 2018-07-16 stsp If not specified, assume the repository is located at or above the current
125 ecb28ae0 2018-07-16 stsp working directory.
126 030916b5 2018-07-12 stsp .El
127 030916b5 2018-07-12 stsp .It Cm diff [ Ar repository-path ] Ar object1 Ar object2
128 030916b5 2018-07-12 stsp Display the differences between two objects in the repository.
129 030916b5 2018-07-12 stsp Each
130 030916b5 2018-07-12 stsp .Ar object
131 030916b5 2018-07-12 stsp argument is a SHA1 hash which corresponds to the object.
132 030916b5 2018-07-12 stsp Both objects must be of the same type (blobs, trees, or commits).
133 030916b5 2018-07-12 stsp If the
134 030916b5 2018-07-12 stsp .Ar repository path
135 030916b5 2018-07-12 stsp is omitted, use the current working directory.
136 030916b5 2018-07-12 stsp .Pp
137 030916b5 2018-07-12 stsp The key bindings for
138 030916b5 2018-07-12 stsp .Cm tog diff
139 030916b5 2018-07-12 stsp are as follows:
140 030916b5 2018-07-12 stsp .Bl -tag -width Ds
141 dccb68cb 2018-07-12 stsp .It Cm Down-arrow, j, Page-down, Space
142 030916b5 2018-07-12 stsp Scroll down.
143 31607d6c 2018-08-18 stsp .It Cm Up-arrow, k, Page-up
144 030916b5 2018-07-12 stsp Scroll up.
145 bcbd79e2 2018-08-19 stsp .It [
146 bcbd79e2 2018-08-19 stsp Switch to the previous commit in parent
147 bcbd79e2 2018-08-19 stsp .Cm log view .
148 bcbd79e2 2018-08-19 stsp .It ]
149 bcbd79e2 2018-08-19 stsp Switch to the next commit in parent
150 bcbd79e2 2018-08-19 stsp .Cm log view .
151 030916b5 2018-07-12 stsp .El
152 69069811 2018-08-02 stsp .It Cm blame [ Fl c Ar commit ] [ Fl r Ar repository-path ] Ar path
153 030916b5 2018-07-12 stsp Display line-by-line history of a file at the specified path.
154 030916b5 2018-07-12 stsp .Pp
155 030916b5 2018-07-12 stsp The key bindings for
156 030916b5 2018-07-12 stsp .Cm tog blame
157 030916b5 2018-07-12 stsp are as follows:
158 030916b5 2018-07-12 stsp .Bl -tag -width Ds
159 38f94530 2018-07-12 stsp .It Cm Down-arrow, j, Page-down, Space
160 030916b5 2018-07-12 stsp Move the selection cursor down.
161 31607d6c 2018-08-18 stsp .It Cm Up-arrow, k, Page-up
162 030916b5 2018-07-12 stsp Move the selection cursor up.
163 030916b5 2018-07-12 stsp .It Cm Enter
164 030916b5 2018-07-12 stsp Switch to the
165 030916b5 2018-07-12 stsp .Cm diff
166 030916b5 2018-07-12 stsp view for the currently selected line's commit.
167 030916b5 2018-07-12 stsp .It Cm b
168 030916b5 2018-07-12 stsp Show the
169 030916b5 2018-07-12 stsp .Cm blame
170 030916b5 2018-07-12 stsp view for the version of the file in the currently selected line's commit.
171 7a2921f9 2018-07-12 stsp .It Cm p
172 7a2921f9 2018-07-12 stsp Show the
173 7a2921f9 2018-07-12 stsp .Cm blame
174 7a2921f9 2018-07-12 stsp view for the version of the file in the currently selected line's commit's
175 7a2921f9 2018-07-12 stsp parent commit.
176 030916b5 2018-07-12 stsp .It Cm B
177 030916b5 2018-07-12 stsp Switch the
178 030916b5 2018-07-12 stsp .Cm blame
179 030916b5 2018-07-12 stsp view back to the previously blamed commit.
180 030916b5 2018-07-12 stsp .El
181 030916b5 2018-07-12 stsp .Pp
182 030916b5 2018-07-12 stsp The options for
183 030916b5 2018-07-12 stsp .Cm tog blame
184 030916b5 2018-07-12 stsp are as follows:
185 030916b5 2018-07-12 stsp .Bl -tag -width Ds
186 030916b5 2018-07-12 stsp .It Fl c Ar commit
187 030916b5 2018-07-12 stsp Start traversing history at the specified
188 030916b5 2018-07-12 stsp .Ar commit .
189 030916b5 2018-07-12 stsp The expected argument is the name of a branch or a SHA1 hash which corresponds
190 030916b5 2018-07-12 stsp to a commit object.
191 69069811 2018-08-02 stsp .It Fl r Ar repository-path
192 69069811 2018-08-02 stsp Use the repository at the specified path.
193 69069811 2018-08-02 stsp If not specified, assume the repository is located at or above the current
194 69069811 2018-08-02 stsp working directory.
195 030916b5 2018-07-12 stsp .El
196 030916b5 2018-07-12 stsp .It Cm tree [ Fl c Ar commit ] [ Ar repository-path ]
197 030916b5 2018-07-12 stsp Display the repository tree.
198 030916b5 2018-07-12 stsp If the
199 030916b5 2018-07-12 stsp .Ar repository path
200 030916b5 2018-07-12 stsp is omitted, assume the repository is located in the current working directory.
201 030916b5 2018-07-12 stsp .Pp
202 030916b5 2018-07-12 stsp The key bindings for
203 030916b5 2018-07-12 stsp .Cm tog tree
204 030916b5 2018-07-12 stsp are as follows:
205 030916b5 2018-07-12 stsp .Bl -tag -width Ds
206 030916b5 2018-07-12 stsp .It Cm Down-arrow, j, Page-down
207 030916b5 2018-07-12 stsp Move the selection cursor down.
208 030916b5 2018-07-12 stsp .It Cm Up-arrow, k, Page-up
209 030916b5 2018-07-12 stsp Move the selection cursor up.
210 030916b5 2018-07-12 stsp .It Cm Enter
211 030916b5 2018-07-12 stsp Enter the currently selected directory, or switch to the
212 030916b5 2018-07-12 stsp .Cm blame
213 030916b5 2018-07-12 stsp view for the currently selected file.
214 69efd4c4 2018-07-18 stsp .It Cm l
215 69efd4c4 2018-07-18 stsp Switch to the
216 69efd4c4 2018-07-18 stsp .Cm log
217 69efd4c4 2018-07-18 stsp view for the currently selected tree entry.
218 7837eeac 2018-09-24 stsp .It Cm Backspace
219 030916b5 2018-07-12 stsp Move back to the parent directory.
220 030916b5 2018-07-12 stsp .It Cm i
221 030916b5 2018-07-12 stsp Show the object IDs for all objects displayed in the
222 030916b5 2018-07-12 stsp .Cm tree
223 030916b5 2018-07-12 stsp view.
224 030916b5 2018-07-12 stsp .El
225 030916b5 2018-07-12 stsp .Pp
226 030916b5 2018-07-12 stsp The options for
227 030916b5 2018-07-12 stsp .Cm tog tree
228 030916b5 2018-07-12 stsp are as follows:
229 030916b5 2018-07-12 stsp .Bl -tag -width Ds
230 030916b5 2018-07-12 stsp .It Fl c Ar commit
231 030916b5 2018-07-12 stsp Start traversing history at the specified
232 030916b5 2018-07-12 stsp .Ar commit .
233 030916b5 2018-07-12 stsp The expected argument is the name of a branch or a SHA1 hash which corresponds
234 030916b5 2018-07-12 stsp to a commit object.
235 030916b5 2018-07-12 stsp .El
236 030916b5 2018-07-12 stsp .El
237 030916b5 2018-07-12 stsp .Sh EXIT STATUS
238 030916b5 2018-07-12 stsp .Ex -std tog
239 030916b5 2018-07-12 stsp .Sh SEE ALSO
240 5e5560e1 2018-08-01 stsp .Xr git-repository 5
241 030916b5 2018-07-12 stsp .Sh AUTHORS
242 030916b5 2018-07-12 stsp .An Stefan Sperling Aq Mt stsp@openbsd.org