##// END OF EJS Templates
log: add a status template...
Jordi Gutiérrez Hermoso -
r25006:517763f8 default
parent child Browse files
Show More
@@ -0,0 +1,25 b''
1 %include map-cmdline.default
2
3 # Override base templates
4 changeset = '{cset}{branches}{bookmarks}{tags}{parents}{user}{ldate}{summary}{lfiles}\n'
5 changeset_verbose = '{cset}{branches}{bookmarks}{tags}{parents}{user}{ldate}{description}{lfiles}\n'
6 changeset_debug = '{fullcset}{branches}{bookmarks}{tags}{lphase}{parents}{manifest}{user}{ldate}{extras}{description}{lfiles}\n'
7
8 # Override the file templates
9 lfiles = '{if(files,
10 label('ui.note log.files',
11 'files:\n'))}{lfile_mods}{lfile_adds}{lfile_copies_switch}{lfile_dels}'
12
13 # Exclude copied files, will display those in lfile_copies_switch
14 lfile_adds = '{file_adds % "{ifcontains(file, file_copies_switch,
15 '',
16 '{lfile_add}')}"}'
17 lfile_add = '{label("status.added", "A {file}\n")}'
18
19 lfile_copies_switch = '{file_copies_switch % "{lfile_copy_orig}{lfile_copy_dest}"'
20 lfile_copy_orig = '{label("status.added", "A {name}\n")}'
21 lfile_copy_dest = '{label("status.copied", " {source}\n")}'
22
23 lfile_mods = '{file_mods % "{label('status.modified', 'M {file}\n')}"}'
24
25 lfile_dels = '{file_dels % "{label('status.removed', 'R {file}\n')}"}'
@@ -1,2793 +1,2934 b''
1 $ hg init a
1 $ hg init a
2 $ cd a
2 $ cd a
3 $ echo a > a
3 $ echo a > a
4 $ hg add a
4 $ hg add a
5 $ echo line 1 > b
5 $ echo line 1 > b
6 $ echo line 2 >> b
6 $ echo line 2 >> b
7 $ hg commit -l b -d '1000000 0' -u 'User Name <user@hostname>'
7 $ hg commit -l b -d '1000000 0' -u 'User Name <user@hostname>'
8
8
9 $ hg add b
9 $ hg add b
10 $ echo other 1 > c
10 $ echo other 1 > c
11 $ echo other 2 >> c
11 $ echo other 2 >> c
12 $ echo >> c
12 $ echo >> c
13 $ echo other 3 >> c
13 $ echo other 3 >> c
14 $ hg commit -l c -d '1100000 0' -u 'A. N. Other <other@place>'
14 $ hg commit -l c -d '1100000 0' -u 'A. N. Other <other@place>'
15
15
16 $ hg add c
16 $ hg add c
17 $ hg commit -m 'no person' -d '1200000 0' -u 'other@place'
17 $ hg commit -m 'no person' -d '1200000 0' -u 'other@place'
18 $ echo c >> c
18 $ echo c >> c
19 $ hg commit -m 'no user, no domain' -d '1300000 0' -u 'person'
19 $ hg commit -m 'no user, no domain' -d '1300000 0' -u 'person'
20
20
21 $ echo foo > .hg/branch
21 $ echo foo > .hg/branch
22 $ hg commit -m 'new branch' -d '1400000 0' -u 'person'
22 $ hg commit -m 'new branch' -d '1400000 0' -u 'person'
23
23
24 $ hg co -q 3
24 $ hg co -q 3
25 $ echo other 4 >> d
25 $ echo other 4 >> d
26 $ hg add d
26 $ hg add d
27 $ hg commit -m 'new head' -d '1500000 0' -u 'person'
27 $ hg commit -m 'new head' -d '1500000 0' -u 'person'
28
28
29 $ hg merge -q foo
29 $ hg merge -q foo
30 $ hg commit -m 'merge' -d '1500001 0' -u 'person'
30 $ hg commit -m 'merge' -d '1500001 0' -u 'person'
31
31
32 Second branch starting at nullrev:
32 Second branch starting at nullrev:
33
33
34 $ hg update null
34 $ hg update null
35 0 files updated, 0 files merged, 4 files removed, 0 files unresolved
35 0 files updated, 0 files merged, 4 files removed, 0 files unresolved
36 $ echo second > second
36 $ echo second > second
37 $ hg add second
37 $ hg add second
38 $ hg commit -m second -d '1000000 0' -u 'User Name <user@hostname>'
38 $ hg commit -m second -d '1000000 0' -u 'User Name <user@hostname>'
39 created new head
39 created new head
40
40
41 $ echo third > third
41 $ echo third > third
42 $ hg add third
42 $ hg add third
43 $ hg mv second fourth
43 $ hg mv second fourth
44 $ hg commit -m third -d "2020-01-01 10:01"
44 $ hg commit -m third -d "2020-01-01 10:01"
45
45
46 $ hg log --template '{join(file_copies, ",\n")}\n' -r .
46 $ hg log --template '{join(file_copies, ",\n")}\n' -r .
47 fourth (second)
47 fourth (second)
48 $ hg log -T '{file_copies % "{source} -> {name}\n"}' -r .
48 $ hg log -T '{file_copies % "{source} -> {name}\n"}' -r .
49 second -> fourth
49 second -> fourth
50 $ hg log -T '{rev} {ifcontains("fourth", file_copies, "t", "f")}\n' -r .:7
50 $ hg log -T '{rev} {ifcontains("fourth", file_copies, "t", "f")}\n' -r .:7
51 8 t
51 8 t
52 7 f
52 7 f
53
53
54 Quoting for ui.logtemplate
54 Quoting for ui.logtemplate
55
55
56 $ hg tip --config "ui.logtemplate={rev}\n"
56 $ hg tip --config "ui.logtemplate={rev}\n"
57 8
57 8
58 $ hg tip --config "ui.logtemplate='{rev}\n'"
58 $ hg tip --config "ui.logtemplate='{rev}\n'"
59 8
59 8
60 $ hg tip --config 'ui.logtemplate="{rev}\n"'
60 $ hg tip --config 'ui.logtemplate="{rev}\n"'
61 8
61 8
62
62
63 Make sure user/global hgrc does not affect tests
63 Make sure user/global hgrc does not affect tests
64
64
65 $ echo '[ui]' > .hg/hgrc
65 $ echo '[ui]' > .hg/hgrc
66 $ echo 'logtemplate =' >> .hg/hgrc
66 $ echo 'logtemplate =' >> .hg/hgrc
67 $ echo 'style =' >> .hg/hgrc
67 $ echo 'style =' >> .hg/hgrc
68
68
69 Add some simple styles to settings
69 Add some simple styles to settings
70
70
71 $ echo '[templates]' >> .hg/hgrc
71 $ echo '[templates]' >> .hg/hgrc
72 $ printf 'simple = "{rev}\\n"\n' >> .hg/hgrc
72 $ printf 'simple = "{rev}\\n"\n' >> .hg/hgrc
73 $ printf 'simple2 = {rev}\\n\n' >> .hg/hgrc
73 $ printf 'simple2 = {rev}\\n\n' >> .hg/hgrc
74
74
75 $ hg log -l1 -Tsimple
75 $ hg log -l1 -Tsimple
76 8
76 8
77 $ hg log -l1 -Tsimple2
77 $ hg log -l1 -Tsimple2
78 8
78 8
79
79
80 Test templates and style maps in files:
80 Test templates and style maps in files:
81
81
82 $ echo "{rev}" > tmpl
82 $ echo "{rev}" > tmpl
83 $ hg log -l1 -T./tmpl
83 $ hg log -l1 -T./tmpl
84 8
84 8
85 $ hg log -l1 -Tblah/blah
85 $ hg log -l1 -Tblah/blah
86 blah/blah (no-eol)
86 blah/blah (no-eol)
87
87
88 $ printf 'changeset = "{rev}\\n"\n' > map-simple
88 $ printf 'changeset = "{rev}\\n"\n' > map-simple
89 $ hg log -l1 -T./map-simple
89 $ hg log -l1 -T./map-simple
90 8
90 8
91
91
92 Template should precede style option
92 Template should precede style option
93
93
94 $ hg log -l1 --style default -T '{rev}\n'
94 $ hg log -l1 --style default -T '{rev}\n'
95 8
95 8
96
96
97 Add a commit with empty description, to ensure that the templates
97 Add a commit with empty description, to ensure that the templates
98 below will omit the description line.
98 below will omit the description line.
99
99
100 $ echo c >> c
100 $ echo c >> c
101 $ hg add c
101 $ hg add c
102 $ hg commit -qm ' '
102 $ hg commit -qm ' '
103
103
104 Default style is like normal output. Phases style should be the same
104 Default style is like normal output. Phases style should be the same
105 as default style, except for extra phase lines.
105 as default style, except for extra phase lines.
106
106
107 $ hg log > log.out
107 $ hg log > log.out
108 $ hg log --style default > style.out
108 $ hg log --style default > style.out
109 $ cmp log.out style.out || diff -u log.out style.out
109 $ cmp log.out style.out || diff -u log.out style.out
110 $ hg log -T phases > phases.out
110 $ hg log -T phases > phases.out
111 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
111 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
112 @@ -2,0 +3 @@
112 @@ -2,0 +3 @@
113 +phase: draft
113 +phase: draft
114 @@ -6,0 +8 @@
114 @@ -6,0 +8 @@
115 +phase: draft
115 +phase: draft
116 @@ -11,0 +14 @@
116 @@ -11,0 +14 @@
117 +phase: draft
117 +phase: draft
118 @@ -17,0 +21 @@
118 @@ -17,0 +21 @@
119 +phase: draft
119 +phase: draft
120 @@ -24,0 +29 @@
120 @@ -24,0 +29 @@
121 +phase: draft
121 +phase: draft
122 @@ -31,0 +37 @@
122 @@ -31,0 +37 @@
123 +phase: draft
123 +phase: draft
124 @@ -36,0 +43 @@
124 @@ -36,0 +43 @@
125 +phase: draft
125 +phase: draft
126 @@ -41,0 +49 @@
126 @@ -41,0 +49 @@
127 +phase: draft
127 +phase: draft
128 @@ -46,0 +55 @@
128 @@ -46,0 +55 @@
129 +phase: draft
129 +phase: draft
130 @@ -51,0 +61 @@
130 @@ -51,0 +61 @@
131 +phase: draft
131 +phase: draft
132
132
133 $ hg log -v > log.out
133 $ hg log -v > log.out
134 $ hg log -v --style default > style.out
134 $ hg log -v --style default > style.out
135 $ cmp log.out style.out || diff -u log.out style.out
135 $ cmp log.out style.out || diff -u log.out style.out
136 $ hg log -v -T phases > phases.out
136 $ hg log -v -T phases > phases.out
137 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
137 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
138 @@ -2,0 +3 @@
138 @@ -2,0 +3 @@
139 +phase: draft
139 +phase: draft
140 @@ -7,0 +9 @@
140 @@ -7,0 +9 @@
141 +phase: draft
141 +phase: draft
142 @@ -15,0 +18 @@
142 @@ -15,0 +18 @@
143 +phase: draft
143 +phase: draft
144 @@ -24,0 +28 @@
144 @@ -24,0 +28 @@
145 +phase: draft
145 +phase: draft
146 @@ -33,0 +38 @@
146 @@ -33,0 +38 @@
147 +phase: draft
147 +phase: draft
148 @@ -43,0 +49 @@
148 @@ -43,0 +49 @@
149 +phase: draft
149 +phase: draft
150 @@ -50,0 +57 @@
150 @@ -50,0 +57 @@
151 +phase: draft
151 +phase: draft
152 @@ -58,0 +66 @@
152 @@ -58,0 +66 @@
153 +phase: draft
153 +phase: draft
154 @@ -66,0 +75 @@
154 @@ -66,0 +75 @@
155 +phase: draft
155 +phase: draft
156 @@ -77,0 +87 @@
156 @@ -77,0 +87 @@
157 +phase: draft
157 +phase: draft
158
158
159 $ hg log -q > log.out
159 $ hg log -q > log.out
160 $ hg log -q --style default > style.out
160 $ hg log -q --style default > style.out
161 $ cmp log.out style.out || diff -u log.out style.out
161 $ cmp log.out style.out || diff -u log.out style.out
162 $ hg log -q -T phases > phases.out
162 $ hg log -q -T phases > phases.out
163 $ cmp log.out phases.out || diff -u log.out phases.out
163 $ cmp log.out phases.out || diff -u log.out phases.out
164
164
165 $ hg log --debug > log.out
165 $ hg log --debug > log.out
166 $ hg log --debug --style default > style.out
166 $ hg log --debug --style default > style.out
167 $ cmp log.out style.out || diff -u log.out style.out
167 $ cmp log.out style.out || diff -u log.out style.out
168 $ hg log --debug -T phases > phases.out
168 $ hg log --debug -T phases > phases.out
169 $ cmp log.out phases.out || diff -u log.out phases.out
169 $ cmp log.out phases.out || diff -u log.out phases.out
170
170
171 Default style should also preserve color information (issue2866):
171 Default style should also preserve color information (issue2866):
172
172
173 $ cp $HGRCPATH $HGRCPATH-bak
173 $ cp $HGRCPATH $HGRCPATH-bak
174 $ cat <<EOF >> $HGRCPATH
174 $ cat <<EOF >> $HGRCPATH
175 > [extensions]
175 > [extensions]
176 > color=
176 > color=
177 > EOF
177 > EOF
178
178
179 $ hg --color=debug log > log.out
179 $ hg --color=debug log > log.out
180 $ hg --color=debug log --style default > style.out
180 $ hg --color=debug log --style default > style.out
181 $ cmp log.out style.out || diff -u log.out style.out
181 $ cmp log.out style.out || diff -u log.out style.out
182 $ hg --color=debug log -T phases > phases.out
182 $ hg --color=debug log -T phases > phases.out
183 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
183 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
184 @@ -2,0 +3 @@
184 @@ -2,0 +3 @@
185 +[log.phase|phase: draft]
185 +[log.phase|phase: draft]
186 @@ -6,0 +8 @@
186 @@ -6,0 +8 @@
187 +[log.phase|phase: draft]
187 +[log.phase|phase: draft]
188 @@ -11,0 +14 @@
188 @@ -11,0 +14 @@
189 +[log.phase|phase: draft]
189 +[log.phase|phase: draft]
190 @@ -17,0 +21 @@
190 @@ -17,0 +21 @@
191 +[log.phase|phase: draft]
191 +[log.phase|phase: draft]
192 @@ -24,0 +29 @@
192 @@ -24,0 +29 @@
193 +[log.phase|phase: draft]
193 +[log.phase|phase: draft]
194 @@ -31,0 +37 @@
194 @@ -31,0 +37 @@
195 +[log.phase|phase: draft]
195 +[log.phase|phase: draft]
196 @@ -36,0 +43 @@
196 @@ -36,0 +43 @@
197 +[log.phase|phase: draft]
197 +[log.phase|phase: draft]
198 @@ -41,0 +49 @@
198 @@ -41,0 +49 @@
199 +[log.phase|phase: draft]
199 +[log.phase|phase: draft]
200 @@ -46,0 +55 @@
200 @@ -46,0 +55 @@
201 +[log.phase|phase: draft]
201 +[log.phase|phase: draft]
202 @@ -51,0 +61 @@
202 @@ -51,0 +61 @@
203 +[log.phase|phase: draft]
203 +[log.phase|phase: draft]
204
204
205 $ hg --color=debug -v log > log.out
205 $ hg --color=debug -v log > log.out
206 $ hg --color=debug -v log --style default > style.out
206 $ hg --color=debug -v log --style default > style.out
207 $ cmp log.out style.out || diff -u log.out style.out
207 $ cmp log.out style.out || diff -u log.out style.out
208 $ hg --color=debug -v log -T phases > phases.out
208 $ hg --color=debug -v log -T phases > phases.out
209 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
209 $ diff -U 0 log.out phases.out | grep -v '^---\|^+++'
210 @@ -2,0 +3 @@
210 @@ -2,0 +3 @@
211 +[log.phase|phase: draft]
211 +[log.phase|phase: draft]
212 @@ -7,0 +9 @@
212 @@ -7,0 +9 @@
213 +[log.phase|phase: draft]
213 +[log.phase|phase: draft]
214 @@ -15,0 +18 @@
214 @@ -15,0 +18 @@
215 +[log.phase|phase: draft]
215 +[log.phase|phase: draft]
216 @@ -24,0 +28 @@
216 @@ -24,0 +28 @@
217 +[log.phase|phase: draft]
217 +[log.phase|phase: draft]
218 @@ -33,0 +38 @@
218 @@ -33,0 +38 @@
219 +[log.phase|phase: draft]
219 +[log.phase|phase: draft]
220 @@ -43,0 +49 @@
220 @@ -43,0 +49 @@
221 +[log.phase|phase: draft]
221 +[log.phase|phase: draft]
222 @@ -50,0 +57 @@
222 @@ -50,0 +57 @@
223 +[log.phase|phase: draft]
223 +[log.phase|phase: draft]
224 @@ -58,0 +66 @@
224 @@ -58,0 +66 @@
225 +[log.phase|phase: draft]
225 +[log.phase|phase: draft]
226 @@ -66,0 +75 @@
226 @@ -66,0 +75 @@
227 +[log.phase|phase: draft]
227 +[log.phase|phase: draft]
228 @@ -77,0 +87 @@
228 @@ -77,0 +87 @@
229 +[log.phase|phase: draft]
229 +[log.phase|phase: draft]
230
230
231 $ hg --color=debug -q log > log.out
231 $ hg --color=debug -q log > log.out
232 $ hg --color=debug -q log --style default > style.out
232 $ hg --color=debug -q log --style default > style.out
233 $ cmp log.out style.out || diff -u log.out style.out
233 $ cmp log.out style.out || diff -u log.out style.out
234 $ hg --color=debug -q log -T phases > phases.out
234 $ hg --color=debug -q log -T phases > phases.out
235 $ cmp log.out phases.out || diff -u log.out phases.out
235 $ cmp log.out phases.out || diff -u log.out phases.out
236
236
237 $ hg --color=debug --debug log > log.out
237 $ hg --color=debug --debug log > log.out
238 $ hg --color=debug --debug log --style default > style.out
238 $ hg --color=debug --debug log --style default > style.out
239 $ cmp log.out style.out || diff -u log.out style.out
239 $ cmp log.out style.out || diff -u log.out style.out
240 $ hg --color=debug --debug log -T phases > phases.out
240 $ hg --color=debug --debug log -T phases > phases.out
241 $ cmp log.out phases.out || diff -u log.out phases.out
241 $ cmp log.out phases.out || diff -u log.out phases.out
242
242
243 $ mv $HGRCPATH-bak $HGRCPATH
243 $ mv $HGRCPATH-bak $HGRCPATH
244
244
245 Remove commit with empty commit message, so as to not pollute further
245 Remove commit with empty commit message, so as to not pollute further
246 tests.
246 tests.
247
247
248 $ hg --config extensions.strip= strip -q .
248 $ hg --config extensions.strip= strip -q .
249
249
250 Revision with no copies (used to print a traceback):
250 Revision with no copies (used to print a traceback):
251
251
252 $ hg tip -v --template '\n'
252 $ hg tip -v --template '\n'
253
253
254
254
255 Compact style works:
255 Compact style works:
256
256
257 $ hg log -Tcompact
257 $ hg log -Tcompact
258 8[tip] 95c24699272e 2020-01-01 10:01 +0000 test
258 8[tip] 95c24699272e 2020-01-01 10:01 +0000 test
259 third
259 third
260
260
261 7:-1 29114dbae42b 1970-01-12 13:46 +0000 user
261 7:-1 29114dbae42b 1970-01-12 13:46 +0000 user
262 second
262 second
263
263
264 6:5,4 d41e714fe50d 1970-01-18 08:40 +0000 person
264 6:5,4 d41e714fe50d 1970-01-18 08:40 +0000 person
265 merge
265 merge
266
266
267 5:3 13207e5a10d9 1970-01-18 08:40 +0000 person
267 5:3 13207e5a10d9 1970-01-18 08:40 +0000 person
268 new head
268 new head
269
269
270 4 bbe44766e73d 1970-01-17 04:53 +0000 person
270 4 bbe44766e73d 1970-01-17 04:53 +0000 person
271 new branch
271 new branch
272
272
273 3 10e46f2dcbf4 1970-01-16 01:06 +0000 person
273 3 10e46f2dcbf4 1970-01-16 01:06 +0000 person
274 no user, no domain
274 no user, no domain
275
275
276 2 97054abb4ab8 1970-01-14 21:20 +0000 other
276 2 97054abb4ab8 1970-01-14 21:20 +0000 other
277 no person
277 no person
278
278
279 1 b608e9d1a3f0 1970-01-13 17:33 +0000 other
279 1 b608e9d1a3f0 1970-01-13 17:33 +0000 other
280 other 1
280 other 1
281
281
282 0 1e4e1b8f71e0 1970-01-12 13:46 +0000 user
282 0 1e4e1b8f71e0 1970-01-12 13:46 +0000 user
283 line 1
283 line 1
284
284
285
285
286 $ hg log -v --style compact
286 $ hg log -v --style compact
287 8[tip] 95c24699272e 2020-01-01 10:01 +0000 test
287 8[tip] 95c24699272e 2020-01-01 10:01 +0000 test
288 third
288 third
289
289
290 7:-1 29114dbae42b 1970-01-12 13:46 +0000 User Name <user@hostname>
290 7:-1 29114dbae42b 1970-01-12 13:46 +0000 User Name <user@hostname>
291 second
291 second
292
292
293 6:5,4 d41e714fe50d 1970-01-18 08:40 +0000 person
293 6:5,4 d41e714fe50d 1970-01-18 08:40 +0000 person
294 merge
294 merge
295
295
296 5:3 13207e5a10d9 1970-01-18 08:40 +0000 person
296 5:3 13207e5a10d9 1970-01-18 08:40 +0000 person
297 new head
297 new head
298
298
299 4 bbe44766e73d 1970-01-17 04:53 +0000 person
299 4 bbe44766e73d 1970-01-17 04:53 +0000 person
300 new branch
300 new branch
301
301
302 3 10e46f2dcbf4 1970-01-16 01:06 +0000 person
302 3 10e46f2dcbf4 1970-01-16 01:06 +0000 person
303 no user, no domain
303 no user, no domain
304
304
305 2 97054abb4ab8 1970-01-14 21:20 +0000 other@place
305 2 97054abb4ab8 1970-01-14 21:20 +0000 other@place
306 no person
306 no person
307
307
308 1 b608e9d1a3f0 1970-01-13 17:33 +0000 A. N. Other <other@place>
308 1 b608e9d1a3f0 1970-01-13 17:33 +0000 A. N. Other <other@place>
309 other 1
309 other 1
310 other 2
310 other 2
311
311
312 other 3
312 other 3
313
313
314 0 1e4e1b8f71e0 1970-01-12 13:46 +0000 User Name <user@hostname>
314 0 1e4e1b8f71e0 1970-01-12 13:46 +0000 User Name <user@hostname>
315 line 1
315 line 1
316 line 2
316 line 2
317
317
318
318
319 $ hg log --debug --style compact
319 $ hg log --debug --style compact
320 8[tip]:7,-1 95c24699272e 2020-01-01 10:01 +0000 test
320 8[tip]:7,-1 95c24699272e 2020-01-01 10:01 +0000 test
321 third
321 third
322
322
323 7:-1,-1 29114dbae42b 1970-01-12 13:46 +0000 User Name <user@hostname>
323 7:-1,-1 29114dbae42b 1970-01-12 13:46 +0000 User Name <user@hostname>
324 second
324 second
325
325
326 6:5,4 d41e714fe50d 1970-01-18 08:40 +0000 person
326 6:5,4 d41e714fe50d 1970-01-18 08:40 +0000 person
327 merge
327 merge
328
328
329 5:3,-1 13207e5a10d9 1970-01-18 08:40 +0000 person
329 5:3,-1 13207e5a10d9 1970-01-18 08:40 +0000 person
330 new head
330 new head
331
331
332 4:3,-1 bbe44766e73d 1970-01-17 04:53 +0000 person
332 4:3,-1 bbe44766e73d 1970-01-17 04:53 +0000 person
333 new branch
333 new branch
334
334
335 3:2,-1 10e46f2dcbf4 1970-01-16 01:06 +0000 person
335 3:2,-1 10e46f2dcbf4 1970-01-16 01:06 +0000 person
336 no user, no domain
336 no user, no domain
337
337
338 2:1,-1 97054abb4ab8 1970-01-14 21:20 +0000 other@place
338 2:1,-1 97054abb4ab8 1970-01-14 21:20 +0000 other@place
339 no person
339 no person
340
340
341 1:0,-1 b608e9d1a3f0 1970-01-13 17:33 +0000 A. N. Other <other@place>
341 1:0,-1 b608e9d1a3f0 1970-01-13 17:33 +0000 A. N. Other <other@place>
342 other 1
342 other 1
343 other 2
343 other 2
344
344
345 other 3
345 other 3
346
346
347 0:-1,-1 1e4e1b8f71e0 1970-01-12 13:46 +0000 User Name <user@hostname>
347 0:-1,-1 1e4e1b8f71e0 1970-01-12 13:46 +0000 User Name <user@hostname>
348 line 1
348 line 1
349 line 2
349 line 2
350
350
351
351
352 Test xml styles:
352 Test xml styles:
353
353
354 $ hg log --style xml
354 $ hg log --style xml
355 <?xml version="1.0"?>
355 <?xml version="1.0"?>
356 <log>
356 <log>
357 <logentry revision="8" node="95c24699272ef57d062b8bccc32c878bf841784a">
357 <logentry revision="8" node="95c24699272ef57d062b8bccc32c878bf841784a">
358 <tag>tip</tag>
358 <tag>tip</tag>
359 <author email="test">test</author>
359 <author email="test">test</author>
360 <date>2020-01-01T10:01:00+00:00</date>
360 <date>2020-01-01T10:01:00+00:00</date>
361 <msg xml:space="preserve">third</msg>
361 <msg xml:space="preserve">third</msg>
362 </logentry>
362 </logentry>
363 <logentry revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453">
363 <logentry revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453">
364 <parent revision="-1" node="0000000000000000000000000000000000000000" />
364 <parent revision="-1" node="0000000000000000000000000000000000000000" />
365 <author email="user@hostname">User Name</author>
365 <author email="user@hostname">User Name</author>
366 <date>1970-01-12T13:46:40+00:00</date>
366 <date>1970-01-12T13:46:40+00:00</date>
367 <msg xml:space="preserve">second</msg>
367 <msg xml:space="preserve">second</msg>
368 </logentry>
368 </logentry>
369 <logentry revision="6" node="d41e714fe50d9e4a5f11b4d595d543481b5f980b">
369 <logentry revision="6" node="d41e714fe50d9e4a5f11b4d595d543481b5f980b">
370 <parent revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f" />
370 <parent revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f" />
371 <parent revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74" />
371 <parent revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74" />
372 <author email="person">person</author>
372 <author email="person">person</author>
373 <date>1970-01-18T08:40:01+00:00</date>
373 <date>1970-01-18T08:40:01+00:00</date>
374 <msg xml:space="preserve">merge</msg>
374 <msg xml:space="preserve">merge</msg>
375 </logentry>
375 </logentry>
376 <logentry revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f">
376 <logentry revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f">
377 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
377 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
378 <author email="person">person</author>
378 <author email="person">person</author>
379 <date>1970-01-18T08:40:00+00:00</date>
379 <date>1970-01-18T08:40:00+00:00</date>
380 <msg xml:space="preserve">new head</msg>
380 <msg xml:space="preserve">new head</msg>
381 </logentry>
381 </logentry>
382 <logentry revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74">
382 <logentry revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74">
383 <branch>foo</branch>
383 <branch>foo</branch>
384 <author email="person">person</author>
384 <author email="person">person</author>
385 <date>1970-01-17T04:53:20+00:00</date>
385 <date>1970-01-17T04:53:20+00:00</date>
386 <msg xml:space="preserve">new branch</msg>
386 <msg xml:space="preserve">new branch</msg>
387 </logentry>
387 </logentry>
388 <logentry revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47">
388 <logentry revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47">
389 <author email="person">person</author>
389 <author email="person">person</author>
390 <date>1970-01-16T01:06:40+00:00</date>
390 <date>1970-01-16T01:06:40+00:00</date>
391 <msg xml:space="preserve">no user, no domain</msg>
391 <msg xml:space="preserve">no user, no domain</msg>
392 </logentry>
392 </logentry>
393 <logentry revision="2" node="97054abb4ab824450e9164180baf491ae0078465">
393 <logentry revision="2" node="97054abb4ab824450e9164180baf491ae0078465">
394 <author email="other@place">other</author>
394 <author email="other@place">other</author>
395 <date>1970-01-14T21:20:00+00:00</date>
395 <date>1970-01-14T21:20:00+00:00</date>
396 <msg xml:space="preserve">no person</msg>
396 <msg xml:space="preserve">no person</msg>
397 </logentry>
397 </logentry>
398 <logentry revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965">
398 <logentry revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965">
399 <author email="other@place">A. N. Other</author>
399 <author email="other@place">A. N. Other</author>
400 <date>1970-01-13T17:33:20+00:00</date>
400 <date>1970-01-13T17:33:20+00:00</date>
401 <msg xml:space="preserve">other 1
401 <msg xml:space="preserve">other 1
402 other 2
402 other 2
403
403
404 other 3</msg>
404 other 3</msg>
405 </logentry>
405 </logentry>
406 <logentry revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f">
406 <logentry revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f">
407 <author email="user@hostname">User Name</author>
407 <author email="user@hostname">User Name</author>
408 <date>1970-01-12T13:46:40+00:00</date>
408 <date>1970-01-12T13:46:40+00:00</date>
409 <msg xml:space="preserve">line 1
409 <msg xml:space="preserve">line 1
410 line 2</msg>
410 line 2</msg>
411 </logentry>
411 </logentry>
412 </log>
412 </log>
413
413
414 $ hg log -v --style xml
414 $ hg log -v --style xml
415 <?xml version="1.0"?>
415 <?xml version="1.0"?>
416 <log>
416 <log>
417 <logentry revision="8" node="95c24699272ef57d062b8bccc32c878bf841784a">
417 <logentry revision="8" node="95c24699272ef57d062b8bccc32c878bf841784a">
418 <tag>tip</tag>
418 <tag>tip</tag>
419 <author email="test">test</author>
419 <author email="test">test</author>
420 <date>2020-01-01T10:01:00+00:00</date>
420 <date>2020-01-01T10:01:00+00:00</date>
421 <msg xml:space="preserve">third</msg>
421 <msg xml:space="preserve">third</msg>
422 <paths>
422 <paths>
423 <path action="A">fourth</path>
423 <path action="A">fourth</path>
424 <path action="A">third</path>
424 <path action="A">third</path>
425 <path action="R">second</path>
425 <path action="R">second</path>
426 </paths>
426 </paths>
427 <copies>
427 <copies>
428 <copy source="second">fourth</copy>
428 <copy source="second">fourth</copy>
429 </copies>
429 </copies>
430 </logentry>
430 </logentry>
431 <logentry revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453">
431 <logentry revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453">
432 <parent revision="-1" node="0000000000000000000000000000000000000000" />
432 <parent revision="-1" node="0000000000000000000000000000000000000000" />
433 <author email="user@hostname">User Name</author>
433 <author email="user@hostname">User Name</author>
434 <date>1970-01-12T13:46:40+00:00</date>
434 <date>1970-01-12T13:46:40+00:00</date>
435 <msg xml:space="preserve">second</msg>
435 <msg xml:space="preserve">second</msg>
436 <paths>
436 <paths>
437 <path action="A">second</path>
437 <path action="A">second</path>
438 </paths>
438 </paths>
439 </logentry>
439 </logentry>
440 <logentry revision="6" node="d41e714fe50d9e4a5f11b4d595d543481b5f980b">
440 <logentry revision="6" node="d41e714fe50d9e4a5f11b4d595d543481b5f980b">
441 <parent revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f" />
441 <parent revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f" />
442 <parent revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74" />
442 <parent revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74" />
443 <author email="person">person</author>
443 <author email="person">person</author>
444 <date>1970-01-18T08:40:01+00:00</date>
444 <date>1970-01-18T08:40:01+00:00</date>
445 <msg xml:space="preserve">merge</msg>
445 <msg xml:space="preserve">merge</msg>
446 <paths>
446 <paths>
447 </paths>
447 </paths>
448 </logentry>
448 </logentry>
449 <logentry revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f">
449 <logentry revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f">
450 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
450 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
451 <author email="person">person</author>
451 <author email="person">person</author>
452 <date>1970-01-18T08:40:00+00:00</date>
452 <date>1970-01-18T08:40:00+00:00</date>
453 <msg xml:space="preserve">new head</msg>
453 <msg xml:space="preserve">new head</msg>
454 <paths>
454 <paths>
455 <path action="A">d</path>
455 <path action="A">d</path>
456 </paths>
456 </paths>
457 </logentry>
457 </logentry>
458 <logentry revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74">
458 <logentry revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74">
459 <branch>foo</branch>
459 <branch>foo</branch>
460 <author email="person">person</author>
460 <author email="person">person</author>
461 <date>1970-01-17T04:53:20+00:00</date>
461 <date>1970-01-17T04:53:20+00:00</date>
462 <msg xml:space="preserve">new branch</msg>
462 <msg xml:space="preserve">new branch</msg>
463 <paths>
463 <paths>
464 </paths>
464 </paths>
465 </logentry>
465 </logentry>
466 <logentry revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47">
466 <logentry revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47">
467 <author email="person">person</author>
467 <author email="person">person</author>
468 <date>1970-01-16T01:06:40+00:00</date>
468 <date>1970-01-16T01:06:40+00:00</date>
469 <msg xml:space="preserve">no user, no domain</msg>
469 <msg xml:space="preserve">no user, no domain</msg>
470 <paths>
470 <paths>
471 <path action="M">c</path>
471 <path action="M">c</path>
472 </paths>
472 </paths>
473 </logentry>
473 </logentry>
474 <logentry revision="2" node="97054abb4ab824450e9164180baf491ae0078465">
474 <logentry revision="2" node="97054abb4ab824450e9164180baf491ae0078465">
475 <author email="other@place">other</author>
475 <author email="other@place">other</author>
476 <date>1970-01-14T21:20:00+00:00</date>
476 <date>1970-01-14T21:20:00+00:00</date>
477 <msg xml:space="preserve">no person</msg>
477 <msg xml:space="preserve">no person</msg>
478 <paths>
478 <paths>
479 <path action="A">c</path>
479 <path action="A">c</path>
480 </paths>
480 </paths>
481 </logentry>
481 </logentry>
482 <logentry revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965">
482 <logentry revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965">
483 <author email="other@place">A. N. Other</author>
483 <author email="other@place">A. N. Other</author>
484 <date>1970-01-13T17:33:20+00:00</date>
484 <date>1970-01-13T17:33:20+00:00</date>
485 <msg xml:space="preserve">other 1
485 <msg xml:space="preserve">other 1
486 other 2
486 other 2
487
487
488 other 3</msg>
488 other 3</msg>
489 <paths>
489 <paths>
490 <path action="A">b</path>
490 <path action="A">b</path>
491 </paths>
491 </paths>
492 </logentry>
492 </logentry>
493 <logentry revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f">
493 <logentry revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f">
494 <author email="user@hostname">User Name</author>
494 <author email="user@hostname">User Name</author>
495 <date>1970-01-12T13:46:40+00:00</date>
495 <date>1970-01-12T13:46:40+00:00</date>
496 <msg xml:space="preserve">line 1
496 <msg xml:space="preserve">line 1
497 line 2</msg>
497 line 2</msg>
498 <paths>
498 <paths>
499 <path action="A">a</path>
499 <path action="A">a</path>
500 </paths>
500 </paths>
501 </logentry>
501 </logentry>
502 </log>
502 </log>
503
503
504 $ hg log --debug --style xml
504 $ hg log --debug --style xml
505 <?xml version="1.0"?>
505 <?xml version="1.0"?>
506 <log>
506 <log>
507 <logentry revision="8" node="95c24699272ef57d062b8bccc32c878bf841784a">
507 <logentry revision="8" node="95c24699272ef57d062b8bccc32c878bf841784a">
508 <tag>tip</tag>
508 <tag>tip</tag>
509 <parent revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453" />
509 <parent revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453" />
510 <parent revision="-1" node="0000000000000000000000000000000000000000" />
510 <parent revision="-1" node="0000000000000000000000000000000000000000" />
511 <author email="test">test</author>
511 <author email="test">test</author>
512 <date>2020-01-01T10:01:00+00:00</date>
512 <date>2020-01-01T10:01:00+00:00</date>
513 <msg xml:space="preserve">third</msg>
513 <msg xml:space="preserve">third</msg>
514 <paths>
514 <paths>
515 <path action="A">fourth</path>
515 <path action="A">fourth</path>
516 <path action="A">third</path>
516 <path action="A">third</path>
517 <path action="R">second</path>
517 <path action="R">second</path>
518 </paths>
518 </paths>
519 <copies>
519 <copies>
520 <copy source="second">fourth</copy>
520 <copy source="second">fourth</copy>
521 </copies>
521 </copies>
522 <extra key="branch">default</extra>
522 <extra key="branch">default</extra>
523 </logentry>
523 </logentry>
524 <logentry revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453">
524 <logentry revision="7" node="29114dbae42b9f078cf2714dbe3a86bba8ec7453">
525 <parent revision="-1" node="0000000000000000000000000000000000000000" />
525 <parent revision="-1" node="0000000000000000000000000000000000000000" />
526 <parent revision="-1" node="0000000000000000000000000000000000000000" />
526 <parent revision="-1" node="0000000000000000000000000000000000000000" />
527 <author email="user@hostname">User Name</author>
527 <author email="user@hostname">User Name</author>
528 <date>1970-01-12T13:46:40+00:00</date>
528 <date>1970-01-12T13:46:40+00:00</date>
529 <msg xml:space="preserve">second</msg>
529 <msg xml:space="preserve">second</msg>
530 <paths>
530 <paths>
531 <path action="A">second</path>
531 <path action="A">second</path>
532 </paths>
532 </paths>
533 <extra key="branch">default</extra>
533 <extra key="branch">default</extra>
534 </logentry>
534 </logentry>
535 <logentry revision="6" node="d41e714fe50d9e4a5f11b4d595d543481b5f980b">
535 <logentry revision="6" node="d41e714fe50d9e4a5f11b4d595d543481b5f980b">
536 <parent revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f" />
536 <parent revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f" />
537 <parent revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74" />
537 <parent revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74" />
538 <author email="person">person</author>
538 <author email="person">person</author>
539 <date>1970-01-18T08:40:01+00:00</date>
539 <date>1970-01-18T08:40:01+00:00</date>
540 <msg xml:space="preserve">merge</msg>
540 <msg xml:space="preserve">merge</msg>
541 <paths>
541 <paths>
542 </paths>
542 </paths>
543 <extra key="branch">default</extra>
543 <extra key="branch">default</extra>
544 </logentry>
544 </logentry>
545 <logentry revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f">
545 <logentry revision="5" node="13207e5a10d9fd28ec424934298e176197f2c67f">
546 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
546 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
547 <parent revision="-1" node="0000000000000000000000000000000000000000" />
547 <parent revision="-1" node="0000000000000000000000000000000000000000" />
548 <author email="person">person</author>
548 <author email="person">person</author>
549 <date>1970-01-18T08:40:00+00:00</date>
549 <date>1970-01-18T08:40:00+00:00</date>
550 <msg xml:space="preserve">new head</msg>
550 <msg xml:space="preserve">new head</msg>
551 <paths>
551 <paths>
552 <path action="A">d</path>
552 <path action="A">d</path>
553 </paths>
553 </paths>
554 <extra key="branch">default</extra>
554 <extra key="branch">default</extra>
555 </logentry>
555 </logentry>
556 <logentry revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74">
556 <logentry revision="4" node="bbe44766e73d5f11ed2177f1838de10c53ef3e74">
557 <branch>foo</branch>
557 <branch>foo</branch>
558 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
558 <parent revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47" />
559 <parent revision="-1" node="0000000000000000000000000000000000000000" />
559 <parent revision="-1" node="0000000000000000000000000000000000000000" />
560 <author email="person">person</author>
560 <author email="person">person</author>
561 <date>1970-01-17T04:53:20+00:00</date>
561 <date>1970-01-17T04:53:20+00:00</date>
562 <msg xml:space="preserve">new branch</msg>
562 <msg xml:space="preserve">new branch</msg>
563 <paths>
563 <paths>
564 </paths>
564 </paths>
565 <extra key="branch">foo</extra>
565 <extra key="branch">foo</extra>
566 </logentry>
566 </logentry>
567 <logentry revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47">
567 <logentry revision="3" node="10e46f2dcbf4823578cf180f33ecf0b957964c47">
568 <parent revision="2" node="97054abb4ab824450e9164180baf491ae0078465" />
568 <parent revision="2" node="97054abb4ab824450e9164180baf491ae0078465" />
569 <parent revision="-1" node="0000000000000000000000000000000000000000" />
569 <parent revision="-1" node="0000000000000000000000000000000000000000" />
570 <author email="person">person</author>
570 <author email="person">person</author>
571 <date>1970-01-16T01:06:40+00:00</date>
571 <date>1970-01-16T01:06:40+00:00</date>
572 <msg xml:space="preserve">no user, no domain</msg>
572 <msg xml:space="preserve">no user, no domain</msg>
573 <paths>
573 <paths>
574 <path action="M">c</path>
574 <path action="M">c</path>
575 </paths>
575 </paths>
576 <extra key="branch">default</extra>
576 <extra key="branch">default</extra>
577 </logentry>
577 </logentry>
578 <logentry revision="2" node="97054abb4ab824450e9164180baf491ae0078465">
578 <logentry revision="2" node="97054abb4ab824450e9164180baf491ae0078465">
579 <parent revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965" />
579 <parent revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965" />
580 <parent revision="-1" node="0000000000000000000000000000000000000000" />
580 <parent revision="-1" node="0000000000000000000000000000000000000000" />
581 <author email="other@place">other</author>
581 <author email="other@place">other</author>
582 <date>1970-01-14T21:20:00+00:00</date>
582 <date>1970-01-14T21:20:00+00:00</date>
583 <msg xml:space="preserve">no person</msg>
583 <msg xml:space="preserve">no person</msg>
584 <paths>
584 <paths>
585 <path action="A">c</path>
585 <path action="A">c</path>
586 </paths>
586 </paths>
587 <extra key="branch">default</extra>
587 <extra key="branch">default</extra>
588 </logentry>
588 </logentry>
589 <logentry revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965">
589 <logentry revision="1" node="b608e9d1a3f0273ccf70fb85fd6866b3482bf965">
590 <parent revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f" />
590 <parent revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f" />
591 <parent revision="-1" node="0000000000000000000000000000000000000000" />
591 <parent revision="-1" node="0000000000000000000000000000000000000000" />
592 <author email="other@place">A. N. Other</author>
592 <author email="other@place">A. N. Other</author>
593 <date>1970-01-13T17:33:20+00:00</date>
593 <date>1970-01-13T17:33:20+00:00</date>
594 <msg xml:space="preserve">other 1
594 <msg xml:space="preserve">other 1
595 other 2
595 other 2
596
596
597 other 3</msg>
597 other 3</msg>
598 <paths>
598 <paths>
599 <path action="A">b</path>
599 <path action="A">b</path>
600 </paths>
600 </paths>
601 <extra key="branch">default</extra>
601 <extra key="branch">default</extra>
602 </logentry>
602 </logentry>
603 <logentry revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f">
603 <logentry revision="0" node="1e4e1b8f71e05681d422154f5421e385fec3454f">
604 <parent revision="-1" node="0000000000000000000000000000000000000000" />
604 <parent revision="-1" node="0000000000000000000000000000000000000000" />
605 <parent revision="-1" node="0000000000000000000000000000000000000000" />
605 <parent revision="-1" node="0000000000000000000000000000000000000000" />
606 <author email="user@hostname">User Name</author>
606 <author email="user@hostname">User Name</author>
607 <date>1970-01-12T13:46:40+00:00</date>
607 <date>1970-01-12T13:46:40+00:00</date>
608 <msg xml:space="preserve">line 1
608 <msg xml:space="preserve">line 1
609 line 2</msg>
609 line 2</msg>
610 <paths>
610 <paths>
611 <path action="A">a</path>
611 <path action="A">a</path>
612 </paths>
612 </paths>
613 <extra key="branch">default</extra>
613 <extra key="branch">default</extra>
614 </logentry>
614 </logentry>
615 </log>
615 </log>
616
616
617
617
618 Test JSON style:
618 Test JSON style:
619
619
620 $ hg log -k nosuch -Tjson
620 $ hg log -k nosuch -Tjson
621 []
621 []
622
622
623 $ hg log -qr . -Tjson
623 $ hg log -qr . -Tjson
624 [
624 [
625 {
625 {
626 "rev": 8,
626 "rev": 8,
627 "node": "95c24699272ef57d062b8bccc32c878bf841784a"
627 "node": "95c24699272ef57d062b8bccc32c878bf841784a"
628 }
628 }
629 ]
629 ]
630
630
631 $ hg log -vpr . -Tjson --stat
631 $ hg log -vpr . -Tjson --stat
632 [
632 [
633 {
633 {
634 "rev": 8,
634 "rev": 8,
635 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
635 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
636 "branch": "default",
636 "branch": "default",
637 "phase": "draft",
637 "phase": "draft",
638 "user": "test",
638 "user": "test",
639 "date": [1577872860, 0],
639 "date": [1577872860, 0],
640 "desc": "third",
640 "desc": "third",
641 "bookmarks": [],
641 "bookmarks": [],
642 "tags": ["tip"],
642 "tags": ["tip"],
643 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
643 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
644 "files": ["fourth", "second", "third"],
644 "files": ["fourth", "second", "third"],
645 "diffstat": " fourth | 1 +\n second | 1 -\n third | 1 +\n 3 files changed, 2 insertions(+), 1 deletions(-)\n",
645 "diffstat": " fourth | 1 +\n second | 1 -\n third | 1 +\n 3 files changed, 2 insertions(+), 1 deletions(-)\n",
646 "diff": "diff -r 29114dbae42b -r 95c24699272e fourth\n--- /dev/null\tThu Jan 01 00:00:00 1970 +0000\n+++ b/fourth\tWed Jan 01 10:01:00 2020 +0000\n@@ -0,0 +1,1 @@\n+second\ndiff -r 29114dbae42b -r 95c24699272e second\n--- a/second\tMon Jan 12 13:46:40 1970 +0000\n+++ /dev/null\tThu Jan 01 00:00:00 1970 +0000\n@@ -1,1 +0,0 @@\n-second\ndiff -r 29114dbae42b -r 95c24699272e third\n--- /dev/null\tThu Jan 01 00:00:00 1970 +0000\n+++ b/third\tWed Jan 01 10:01:00 2020 +0000\n@@ -0,0 +1,1 @@\n+third\n"
646 "diff": "diff -r 29114dbae42b -r 95c24699272e fourth\n--- /dev/null\tThu Jan 01 00:00:00 1970 +0000\n+++ b/fourth\tWed Jan 01 10:01:00 2020 +0000\n@@ -0,0 +1,1 @@\n+second\ndiff -r 29114dbae42b -r 95c24699272e second\n--- a/second\tMon Jan 12 13:46:40 1970 +0000\n+++ /dev/null\tThu Jan 01 00:00:00 1970 +0000\n@@ -1,1 +0,0 @@\n-second\ndiff -r 29114dbae42b -r 95c24699272e third\n--- /dev/null\tThu Jan 01 00:00:00 1970 +0000\n+++ b/third\tWed Jan 01 10:01:00 2020 +0000\n@@ -0,0 +1,1 @@\n+third\n"
647 }
647 }
648 ]
648 ]
649
649
650 honor --git but not format-breaking diffopts
650 honor --git but not format-breaking diffopts
651 $ hg --config diff.noprefix=True log --git -vpr . -Tjson
651 $ hg --config diff.noprefix=True log --git -vpr . -Tjson
652 [
652 [
653 {
653 {
654 "rev": 8,
654 "rev": 8,
655 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
655 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
656 "branch": "default",
656 "branch": "default",
657 "phase": "draft",
657 "phase": "draft",
658 "user": "test",
658 "user": "test",
659 "date": [1577872860, 0],
659 "date": [1577872860, 0],
660 "desc": "third",
660 "desc": "third",
661 "bookmarks": [],
661 "bookmarks": [],
662 "tags": ["tip"],
662 "tags": ["tip"],
663 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
663 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
664 "files": ["fourth", "second", "third"],
664 "files": ["fourth", "second", "third"],
665 "diff": "diff --git a/second b/fourth\nrename from second\nrename to fourth\ndiff --git a/third b/third\nnew file mode 100644\n--- /dev/null\n+++ b/third\n@@ -0,0 +1,1 @@\n+third\n"
665 "diff": "diff --git a/second b/fourth\nrename from second\nrename to fourth\ndiff --git a/third b/third\nnew file mode 100644\n--- /dev/null\n+++ b/third\n@@ -0,0 +1,1 @@\n+third\n"
666 }
666 }
667 ]
667 ]
668
668
669 $ hg log -T json
669 $ hg log -T json
670 [
670 [
671 {
671 {
672 "rev": 8,
672 "rev": 8,
673 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
673 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
674 "branch": "default",
674 "branch": "default",
675 "phase": "draft",
675 "phase": "draft",
676 "user": "test",
676 "user": "test",
677 "date": [1577872860, 0],
677 "date": [1577872860, 0],
678 "desc": "third",
678 "desc": "third",
679 "bookmarks": [],
679 "bookmarks": [],
680 "tags": ["tip"],
680 "tags": ["tip"],
681 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"]
681 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"]
682 },
682 },
683 {
683 {
684 "rev": 7,
684 "rev": 7,
685 "node": "29114dbae42b9f078cf2714dbe3a86bba8ec7453",
685 "node": "29114dbae42b9f078cf2714dbe3a86bba8ec7453",
686 "branch": "default",
686 "branch": "default",
687 "phase": "draft",
687 "phase": "draft",
688 "user": "User Name <user@hostname>",
688 "user": "User Name <user@hostname>",
689 "date": [1000000, 0],
689 "date": [1000000, 0],
690 "desc": "second",
690 "desc": "second",
691 "bookmarks": [],
691 "bookmarks": [],
692 "tags": [],
692 "tags": [],
693 "parents": ["0000000000000000000000000000000000000000"]
693 "parents": ["0000000000000000000000000000000000000000"]
694 },
694 },
695 {
695 {
696 "rev": 6,
696 "rev": 6,
697 "node": "d41e714fe50d9e4a5f11b4d595d543481b5f980b",
697 "node": "d41e714fe50d9e4a5f11b4d595d543481b5f980b",
698 "branch": "default",
698 "branch": "default",
699 "phase": "draft",
699 "phase": "draft",
700 "user": "person",
700 "user": "person",
701 "date": [1500001, 0],
701 "date": [1500001, 0],
702 "desc": "merge",
702 "desc": "merge",
703 "bookmarks": [],
703 "bookmarks": [],
704 "tags": [],
704 "tags": [],
705 "parents": ["13207e5a10d9fd28ec424934298e176197f2c67f", "bbe44766e73d5f11ed2177f1838de10c53ef3e74"]
705 "parents": ["13207e5a10d9fd28ec424934298e176197f2c67f", "bbe44766e73d5f11ed2177f1838de10c53ef3e74"]
706 },
706 },
707 {
707 {
708 "rev": 5,
708 "rev": 5,
709 "node": "13207e5a10d9fd28ec424934298e176197f2c67f",
709 "node": "13207e5a10d9fd28ec424934298e176197f2c67f",
710 "branch": "default",
710 "branch": "default",
711 "phase": "draft",
711 "phase": "draft",
712 "user": "person",
712 "user": "person",
713 "date": [1500000, 0],
713 "date": [1500000, 0],
714 "desc": "new head",
714 "desc": "new head",
715 "bookmarks": [],
715 "bookmarks": [],
716 "tags": [],
716 "tags": [],
717 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"]
717 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"]
718 },
718 },
719 {
719 {
720 "rev": 4,
720 "rev": 4,
721 "node": "bbe44766e73d5f11ed2177f1838de10c53ef3e74",
721 "node": "bbe44766e73d5f11ed2177f1838de10c53ef3e74",
722 "branch": "foo",
722 "branch": "foo",
723 "phase": "draft",
723 "phase": "draft",
724 "user": "person",
724 "user": "person",
725 "date": [1400000, 0],
725 "date": [1400000, 0],
726 "desc": "new branch",
726 "desc": "new branch",
727 "bookmarks": [],
727 "bookmarks": [],
728 "tags": [],
728 "tags": [],
729 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"]
729 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"]
730 },
730 },
731 {
731 {
732 "rev": 3,
732 "rev": 3,
733 "node": "10e46f2dcbf4823578cf180f33ecf0b957964c47",
733 "node": "10e46f2dcbf4823578cf180f33ecf0b957964c47",
734 "branch": "default",
734 "branch": "default",
735 "phase": "draft",
735 "phase": "draft",
736 "user": "person",
736 "user": "person",
737 "date": [1300000, 0],
737 "date": [1300000, 0],
738 "desc": "no user, no domain",
738 "desc": "no user, no domain",
739 "bookmarks": [],
739 "bookmarks": [],
740 "tags": [],
740 "tags": [],
741 "parents": ["97054abb4ab824450e9164180baf491ae0078465"]
741 "parents": ["97054abb4ab824450e9164180baf491ae0078465"]
742 },
742 },
743 {
743 {
744 "rev": 2,
744 "rev": 2,
745 "node": "97054abb4ab824450e9164180baf491ae0078465",
745 "node": "97054abb4ab824450e9164180baf491ae0078465",
746 "branch": "default",
746 "branch": "default",
747 "phase": "draft",
747 "phase": "draft",
748 "user": "other@place",
748 "user": "other@place",
749 "date": [1200000, 0],
749 "date": [1200000, 0],
750 "desc": "no person",
750 "desc": "no person",
751 "bookmarks": [],
751 "bookmarks": [],
752 "tags": [],
752 "tags": [],
753 "parents": ["b608e9d1a3f0273ccf70fb85fd6866b3482bf965"]
753 "parents": ["b608e9d1a3f0273ccf70fb85fd6866b3482bf965"]
754 },
754 },
755 {
755 {
756 "rev": 1,
756 "rev": 1,
757 "node": "b608e9d1a3f0273ccf70fb85fd6866b3482bf965",
757 "node": "b608e9d1a3f0273ccf70fb85fd6866b3482bf965",
758 "branch": "default",
758 "branch": "default",
759 "phase": "draft",
759 "phase": "draft",
760 "user": "A. N. Other <other@place>",
760 "user": "A. N. Other <other@place>",
761 "date": [1100000, 0],
761 "date": [1100000, 0],
762 "desc": "other 1\nother 2\n\nother 3",
762 "desc": "other 1\nother 2\n\nother 3",
763 "bookmarks": [],
763 "bookmarks": [],
764 "tags": [],
764 "tags": [],
765 "parents": ["1e4e1b8f71e05681d422154f5421e385fec3454f"]
765 "parents": ["1e4e1b8f71e05681d422154f5421e385fec3454f"]
766 },
766 },
767 {
767 {
768 "rev": 0,
768 "rev": 0,
769 "node": "1e4e1b8f71e05681d422154f5421e385fec3454f",
769 "node": "1e4e1b8f71e05681d422154f5421e385fec3454f",
770 "branch": "default",
770 "branch": "default",
771 "phase": "draft",
771 "phase": "draft",
772 "user": "User Name <user@hostname>",
772 "user": "User Name <user@hostname>",
773 "date": [1000000, 0],
773 "date": [1000000, 0],
774 "desc": "line 1\nline 2",
774 "desc": "line 1\nline 2",
775 "bookmarks": [],
775 "bookmarks": [],
776 "tags": [],
776 "tags": [],
777 "parents": ["0000000000000000000000000000000000000000"]
777 "parents": ["0000000000000000000000000000000000000000"]
778 }
778 }
779 ]
779 ]
780
780
781 $ hg heads -v -Tjson
781 $ hg heads -v -Tjson
782 [
782 [
783 {
783 {
784 "rev": 8,
784 "rev": 8,
785 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
785 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
786 "branch": "default",
786 "branch": "default",
787 "phase": "draft",
787 "phase": "draft",
788 "user": "test",
788 "user": "test",
789 "date": [1577872860, 0],
789 "date": [1577872860, 0],
790 "desc": "third",
790 "desc": "third",
791 "bookmarks": [],
791 "bookmarks": [],
792 "tags": ["tip"],
792 "tags": ["tip"],
793 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
793 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
794 "files": ["fourth", "second", "third"]
794 "files": ["fourth", "second", "third"]
795 },
795 },
796 {
796 {
797 "rev": 6,
797 "rev": 6,
798 "node": "d41e714fe50d9e4a5f11b4d595d543481b5f980b",
798 "node": "d41e714fe50d9e4a5f11b4d595d543481b5f980b",
799 "branch": "default",
799 "branch": "default",
800 "phase": "draft",
800 "phase": "draft",
801 "user": "person",
801 "user": "person",
802 "date": [1500001, 0],
802 "date": [1500001, 0],
803 "desc": "merge",
803 "desc": "merge",
804 "bookmarks": [],
804 "bookmarks": [],
805 "tags": [],
805 "tags": [],
806 "parents": ["13207e5a10d9fd28ec424934298e176197f2c67f", "bbe44766e73d5f11ed2177f1838de10c53ef3e74"],
806 "parents": ["13207e5a10d9fd28ec424934298e176197f2c67f", "bbe44766e73d5f11ed2177f1838de10c53ef3e74"],
807 "files": []
807 "files": []
808 },
808 },
809 {
809 {
810 "rev": 4,
810 "rev": 4,
811 "node": "bbe44766e73d5f11ed2177f1838de10c53ef3e74",
811 "node": "bbe44766e73d5f11ed2177f1838de10c53ef3e74",
812 "branch": "foo",
812 "branch": "foo",
813 "phase": "draft",
813 "phase": "draft",
814 "user": "person",
814 "user": "person",
815 "date": [1400000, 0],
815 "date": [1400000, 0],
816 "desc": "new branch",
816 "desc": "new branch",
817 "bookmarks": [],
817 "bookmarks": [],
818 "tags": [],
818 "tags": [],
819 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"],
819 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"],
820 "files": []
820 "files": []
821 }
821 }
822 ]
822 ]
823
823
824 $ hg log --debug -Tjson
824 $ hg log --debug -Tjson
825 [
825 [
826 {
826 {
827 "rev": 8,
827 "rev": 8,
828 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
828 "node": "95c24699272ef57d062b8bccc32c878bf841784a",
829 "branch": "default",
829 "branch": "default",
830 "phase": "draft",
830 "phase": "draft",
831 "user": "test",
831 "user": "test",
832 "date": [1577872860, 0],
832 "date": [1577872860, 0],
833 "desc": "third",
833 "desc": "third",
834 "bookmarks": [],
834 "bookmarks": [],
835 "tags": ["tip"],
835 "tags": ["tip"],
836 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
836 "parents": ["29114dbae42b9f078cf2714dbe3a86bba8ec7453"],
837 "manifest": "94961b75a2da554b4df6fb599e5bfc7d48de0c64",
837 "manifest": "94961b75a2da554b4df6fb599e5bfc7d48de0c64",
838 "extra": {"branch": "default"},
838 "extra": {"branch": "default"},
839 "modified": [],
839 "modified": [],
840 "added": ["fourth", "third"],
840 "added": ["fourth", "third"],
841 "removed": ["second"]
841 "removed": ["second"]
842 },
842 },
843 {
843 {
844 "rev": 7,
844 "rev": 7,
845 "node": "29114dbae42b9f078cf2714dbe3a86bba8ec7453",
845 "node": "29114dbae42b9f078cf2714dbe3a86bba8ec7453",
846 "branch": "default",
846 "branch": "default",
847 "phase": "draft",
847 "phase": "draft",
848 "user": "User Name <user@hostname>",
848 "user": "User Name <user@hostname>",
849 "date": [1000000, 0],
849 "date": [1000000, 0],
850 "desc": "second",
850 "desc": "second",
851 "bookmarks": [],
851 "bookmarks": [],
852 "tags": [],
852 "tags": [],
853 "parents": ["0000000000000000000000000000000000000000"],
853 "parents": ["0000000000000000000000000000000000000000"],
854 "manifest": "f2dbc354b94e5ec0b4f10680ee0cee816101d0bf",
854 "manifest": "f2dbc354b94e5ec0b4f10680ee0cee816101d0bf",
855 "extra": {"branch": "default"},
855 "extra": {"branch": "default"},
856 "modified": [],
856 "modified": [],
857 "added": ["second"],
857 "added": ["second"],
858 "removed": []
858 "removed": []
859 },
859 },
860 {
860 {
861 "rev": 6,
861 "rev": 6,
862 "node": "d41e714fe50d9e4a5f11b4d595d543481b5f980b",
862 "node": "d41e714fe50d9e4a5f11b4d595d543481b5f980b",
863 "branch": "default",
863 "branch": "default",
864 "phase": "draft",
864 "phase": "draft",
865 "user": "person",
865 "user": "person",
866 "date": [1500001, 0],
866 "date": [1500001, 0],
867 "desc": "merge",
867 "desc": "merge",
868 "bookmarks": [],
868 "bookmarks": [],
869 "tags": [],
869 "tags": [],
870 "parents": ["13207e5a10d9fd28ec424934298e176197f2c67f", "bbe44766e73d5f11ed2177f1838de10c53ef3e74"],
870 "parents": ["13207e5a10d9fd28ec424934298e176197f2c67f", "bbe44766e73d5f11ed2177f1838de10c53ef3e74"],
871 "manifest": "4dc3def4f9b4c6e8de820f6ee74737f91e96a216",
871 "manifest": "4dc3def4f9b4c6e8de820f6ee74737f91e96a216",
872 "extra": {"branch": "default"},
872 "extra": {"branch": "default"},
873 "modified": [],
873 "modified": [],
874 "added": [],
874 "added": [],
875 "removed": []
875 "removed": []
876 },
876 },
877 {
877 {
878 "rev": 5,
878 "rev": 5,
879 "node": "13207e5a10d9fd28ec424934298e176197f2c67f",
879 "node": "13207e5a10d9fd28ec424934298e176197f2c67f",
880 "branch": "default",
880 "branch": "default",
881 "phase": "draft",
881 "phase": "draft",
882 "user": "person",
882 "user": "person",
883 "date": [1500000, 0],
883 "date": [1500000, 0],
884 "desc": "new head",
884 "desc": "new head",
885 "bookmarks": [],
885 "bookmarks": [],
886 "tags": [],
886 "tags": [],
887 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"],
887 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"],
888 "manifest": "4dc3def4f9b4c6e8de820f6ee74737f91e96a216",
888 "manifest": "4dc3def4f9b4c6e8de820f6ee74737f91e96a216",
889 "extra": {"branch": "default"},
889 "extra": {"branch": "default"},
890 "modified": [],
890 "modified": [],
891 "added": ["d"],
891 "added": ["d"],
892 "removed": []
892 "removed": []
893 },
893 },
894 {
894 {
895 "rev": 4,
895 "rev": 4,
896 "node": "bbe44766e73d5f11ed2177f1838de10c53ef3e74",
896 "node": "bbe44766e73d5f11ed2177f1838de10c53ef3e74",
897 "branch": "foo",
897 "branch": "foo",
898 "phase": "draft",
898 "phase": "draft",
899 "user": "person",
899 "user": "person",
900 "date": [1400000, 0],
900 "date": [1400000, 0],
901 "desc": "new branch",
901 "desc": "new branch",
902 "bookmarks": [],
902 "bookmarks": [],
903 "tags": [],
903 "tags": [],
904 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"],
904 "parents": ["10e46f2dcbf4823578cf180f33ecf0b957964c47"],
905 "manifest": "cb5a1327723bada42f117e4c55a303246eaf9ccc",
905 "manifest": "cb5a1327723bada42f117e4c55a303246eaf9ccc",
906 "extra": {"branch": "foo"},
906 "extra": {"branch": "foo"},
907 "modified": [],
907 "modified": [],
908 "added": [],
908 "added": [],
909 "removed": []
909 "removed": []
910 },
910 },
911 {
911 {
912 "rev": 3,
912 "rev": 3,
913 "node": "10e46f2dcbf4823578cf180f33ecf0b957964c47",
913 "node": "10e46f2dcbf4823578cf180f33ecf0b957964c47",
914 "branch": "default",
914 "branch": "default",
915 "phase": "draft",
915 "phase": "draft",
916 "user": "person",
916 "user": "person",
917 "date": [1300000, 0],
917 "date": [1300000, 0],
918 "desc": "no user, no domain",
918 "desc": "no user, no domain",
919 "bookmarks": [],
919 "bookmarks": [],
920 "tags": [],
920 "tags": [],
921 "parents": ["97054abb4ab824450e9164180baf491ae0078465"],
921 "parents": ["97054abb4ab824450e9164180baf491ae0078465"],
922 "manifest": "cb5a1327723bada42f117e4c55a303246eaf9ccc",
922 "manifest": "cb5a1327723bada42f117e4c55a303246eaf9ccc",
923 "extra": {"branch": "default"},
923 "extra": {"branch": "default"},
924 "modified": ["c"],
924 "modified": ["c"],
925 "added": [],
925 "added": [],
926 "removed": []
926 "removed": []
927 },
927 },
928 {
928 {
929 "rev": 2,
929 "rev": 2,
930 "node": "97054abb4ab824450e9164180baf491ae0078465",
930 "node": "97054abb4ab824450e9164180baf491ae0078465",
931 "branch": "default",
931 "branch": "default",
932 "phase": "draft",
932 "phase": "draft",
933 "user": "other@place",
933 "user": "other@place",
934 "date": [1200000, 0],
934 "date": [1200000, 0],
935 "desc": "no person",
935 "desc": "no person",
936 "bookmarks": [],
936 "bookmarks": [],
937 "tags": [],
937 "tags": [],
938 "parents": ["b608e9d1a3f0273ccf70fb85fd6866b3482bf965"],
938 "parents": ["b608e9d1a3f0273ccf70fb85fd6866b3482bf965"],
939 "manifest": "6e0e82995c35d0d57a52aca8da4e56139e06b4b1",
939 "manifest": "6e0e82995c35d0d57a52aca8da4e56139e06b4b1",
940 "extra": {"branch": "default"},
940 "extra": {"branch": "default"},
941 "modified": [],
941 "modified": [],
942 "added": ["c"],
942 "added": ["c"],
943 "removed": []
943 "removed": []
944 },
944 },
945 {
945 {
946 "rev": 1,
946 "rev": 1,
947 "node": "b608e9d1a3f0273ccf70fb85fd6866b3482bf965",
947 "node": "b608e9d1a3f0273ccf70fb85fd6866b3482bf965",
948 "branch": "default",
948 "branch": "default",
949 "phase": "draft",
949 "phase": "draft",
950 "user": "A. N. Other <other@place>",
950 "user": "A. N. Other <other@place>",
951 "date": [1100000, 0],
951 "date": [1100000, 0],
952 "desc": "other 1\nother 2\n\nother 3",
952 "desc": "other 1\nother 2\n\nother 3",
953 "bookmarks": [],
953 "bookmarks": [],
954 "tags": [],
954 "tags": [],
955 "parents": ["1e4e1b8f71e05681d422154f5421e385fec3454f"],
955 "parents": ["1e4e1b8f71e05681d422154f5421e385fec3454f"],
956 "manifest": "4e8d705b1e53e3f9375e0e60dc7b525d8211fe55",
956 "manifest": "4e8d705b1e53e3f9375e0e60dc7b525d8211fe55",
957 "extra": {"branch": "default"},
957 "extra": {"branch": "default"},
958 "modified": [],
958 "modified": [],
959 "added": ["b"],
959 "added": ["b"],
960 "removed": []
960 "removed": []
961 },
961 },
962 {
962 {
963 "rev": 0,
963 "rev": 0,
964 "node": "1e4e1b8f71e05681d422154f5421e385fec3454f",
964 "node": "1e4e1b8f71e05681d422154f5421e385fec3454f",
965 "branch": "default",
965 "branch": "default",
966 "phase": "draft",
966 "phase": "draft",
967 "user": "User Name <user@hostname>",
967 "user": "User Name <user@hostname>",
968 "date": [1000000, 0],
968 "date": [1000000, 0],
969 "desc": "line 1\nline 2",
969 "desc": "line 1\nline 2",
970 "bookmarks": [],
970 "bookmarks": [],
971 "tags": [],
971 "tags": [],
972 "parents": ["0000000000000000000000000000000000000000"],
972 "parents": ["0000000000000000000000000000000000000000"],
973 "manifest": "a0c8bcbbb45c63b90b70ad007bf38961f64f2af0",
973 "manifest": "a0c8bcbbb45c63b90b70ad007bf38961f64f2af0",
974 "extra": {"branch": "default"},
974 "extra": {"branch": "default"},
975 "modified": [],
975 "modified": [],
976 "added": ["a"],
976 "added": ["a"],
977 "removed": []
977 "removed": []
978 }
978 }
979 ]
979 ]
980
980
981 Error if style not readable:
981 Error if style not readable:
982
982
983 #if unix-permissions no-root
983 #if unix-permissions no-root
984 $ touch q
984 $ touch q
985 $ chmod 0 q
985 $ chmod 0 q
986 $ hg log --style ./q
986 $ hg log --style ./q
987 abort: Permission denied: ./q
987 abort: Permission denied: ./q
988 [255]
988 [255]
989 #endif
989 #endif
990
990
991 Error if no style:
991 Error if no style:
992
992
993 $ hg log --style notexist
993 $ hg log --style notexist
994 abort: style 'notexist' not found
994 abort: style 'notexist' not found
995 (available styles: bisect, changelog, compact, default, phases, xml)
995 (available styles: bisect, changelog, compact, default, phases, status, xml)
996 [255]
996 [255]
997
997
998 $ hg log -T list
998 $ hg log -T list
999 available styles: bisect, changelog, compact, default, phases, xml
999 available styles: bisect, changelog, compact, default, phases, status, xml
1000 abort: specify a template
1000 abort: specify a template
1001 [255]
1001 [255]
1002
1002
1003 Error if style missing key:
1003 Error if style missing key:
1004
1004
1005 $ echo 'q = q' > t
1005 $ echo 'q = q' > t
1006 $ hg log --style ./t
1006 $ hg log --style ./t
1007 abort: "changeset" not in template map
1007 abort: "changeset" not in template map
1008 [255]
1008 [255]
1009
1009
1010 Error if style missing value:
1010 Error if style missing value:
1011
1011
1012 $ echo 'changeset =' > t
1012 $ echo 'changeset =' > t
1013 $ hg log --style t
1013 $ hg log --style t
1014 abort: t:1: missing value
1014 abort: t:1: missing value
1015 [255]
1015 [255]
1016
1016
1017 Error if include fails:
1017 Error if include fails:
1018
1018
1019 $ echo 'changeset = q' >> t
1019 $ echo 'changeset = q' >> t
1020 #if unix-permissions no-root
1020 #if unix-permissions no-root
1021 $ hg log --style ./t
1021 $ hg log --style ./t
1022 abort: template file ./q: Permission denied
1022 abort: template file ./q: Permission denied
1023 [255]
1023 [255]
1024 $ rm q
1024 $ rm q
1025 #endif
1025 #endif
1026
1026
1027 Include works:
1027 Include works:
1028
1028
1029 $ echo '{rev}' > q
1029 $ echo '{rev}' > q
1030 $ hg log --style ./t
1030 $ hg log --style ./t
1031 8
1031 8
1032 7
1032 7
1033 6
1033 6
1034 5
1034 5
1035 4
1035 4
1036 3
1036 3
1037 2
1037 2
1038 1
1038 1
1039 0
1039 0
1040
1040
1041 Check that {phase} works correctly on parents:
1041 Check that {phase} works correctly on parents:
1042
1042
1043 $ cat << EOF > parentphase
1043 $ cat << EOF > parentphase
1044 > changeset_debug = '{rev} ({phase}):{parents}\n'
1044 > changeset_debug = '{rev} ({phase}):{parents}\n'
1045 > parent = ' {rev} ({phase})'
1045 > parent = ' {rev} ({phase})'
1046 > EOF
1046 > EOF
1047 $ hg phase -r 5 --public
1047 $ hg phase -r 5 --public
1048 $ hg phase -r 7 --secret --force
1048 $ hg phase -r 7 --secret --force
1049 $ hg log --debug -G --style ./parentphase
1049 $ hg log --debug -G --style ./parentphase
1050 @ 8 (secret): 7 (secret) -1 (public)
1050 @ 8 (secret): 7 (secret) -1 (public)
1051 |
1051 |
1052 o 7 (secret): -1 (public) -1 (public)
1052 o 7 (secret): -1 (public) -1 (public)
1053
1053
1054 o 6 (draft): 5 (public) 4 (draft)
1054 o 6 (draft): 5 (public) 4 (draft)
1055 |\
1055 |\
1056 | o 5 (public): 3 (public) -1 (public)
1056 | o 5 (public): 3 (public) -1 (public)
1057 | |
1057 | |
1058 o | 4 (draft): 3 (public) -1 (public)
1058 o | 4 (draft): 3 (public) -1 (public)
1059 |/
1059 |/
1060 o 3 (public): 2 (public) -1 (public)
1060 o 3 (public): 2 (public) -1 (public)
1061 |
1061 |
1062 o 2 (public): 1 (public) -1 (public)
1062 o 2 (public): 1 (public) -1 (public)
1063 |
1063 |
1064 o 1 (public): 0 (public) -1 (public)
1064 o 1 (public): 0 (public) -1 (public)
1065 |
1065 |
1066 o 0 (public): -1 (public) -1 (public)
1066 o 0 (public): -1 (public) -1 (public)
1067
1067
1068
1068
1069 Missing non-standard names give no error (backward compatibility):
1069 Missing non-standard names give no error (backward compatibility):
1070
1070
1071 $ echo "changeset = '{c}'" > t
1071 $ echo "changeset = '{c}'" > t
1072 $ hg log --style ./t
1072 $ hg log --style ./t
1073
1073
1074 Defining non-standard name works:
1074 Defining non-standard name works:
1075
1075
1076 $ cat <<EOF > t
1076 $ cat <<EOF > t
1077 > changeset = '{c}'
1077 > changeset = '{c}'
1078 > c = q
1078 > c = q
1079 > EOF
1079 > EOF
1080 $ hg log --style ./t
1080 $ hg log --style ./t
1081 8
1081 8
1082 7
1082 7
1083 6
1083 6
1084 5
1084 5
1085 4
1085 4
1086 3
1086 3
1087 2
1087 2
1088 1
1088 1
1089 0
1089 0
1090
1090
1091 ui.style works:
1091 ui.style works:
1092
1092
1093 $ echo '[ui]' > .hg/hgrc
1093 $ echo '[ui]' > .hg/hgrc
1094 $ echo 'style = t' >> .hg/hgrc
1094 $ echo 'style = t' >> .hg/hgrc
1095 $ hg log
1095 $ hg log
1096 8
1096 8
1097 7
1097 7
1098 6
1098 6
1099 5
1099 5
1100 4
1100 4
1101 3
1101 3
1102 2
1102 2
1103 1
1103 1
1104 0
1104 0
1105
1105
1106
1106
1107 Issue338:
1107 Issue338:
1108
1108
1109 $ hg log --style=changelog > changelog
1109 $ hg log --style=changelog > changelog
1110
1110
1111 $ cat changelog
1111 $ cat changelog
1112 2020-01-01 test <test>
1112 2020-01-01 test <test>
1113
1113
1114 * fourth, second, third:
1114 * fourth, second, third:
1115 third
1115 third
1116 [95c24699272e] [tip]
1116 [95c24699272e] [tip]
1117
1117
1118 1970-01-12 User Name <user@hostname>
1118 1970-01-12 User Name <user@hostname>
1119
1119
1120 * second:
1120 * second:
1121 second
1121 second
1122 [29114dbae42b]
1122 [29114dbae42b]
1123
1123
1124 1970-01-18 person <person>
1124 1970-01-18 person <person>
1125
1125
1126 * merge
1126 * merge
1127 [d41e714fe50d]
1127 [d41e714fe50d]
1128
1128
1129 * d:
1129 * d:
1130 new head
1130 new head
1131 [13207e5a10d9]
1131 [13207e5a10d9]
1132
1132
1133 1970-01-17 person <person>
1133 1970-01-17 person <person>
1134
1134
1135 * new branch
1135 * new branch
1136 [bbe44766e73d] <foo>
1136 [bbe44766e73d] <foo>
1137
1137
1138 1970-01-16 person <person>
1138 1970-01-16 person <person>
1139
1139
1140 * c:
1140 * c:
1141 no user, no domain
1141 no user, no domain
1142 [10e46f2dcbf4]
1142 [10e46f2dcbf4]
1143
1143
1144 1970-01-14 other <other@place>
1144 1970-01-14 other <other@place>
1145
1145
1146 * c:
1146 * c:
1147 no person
1147 no person
1148 [97054abb4ab8]
1148 [97054abb4ab8]
1149
1149
1150 1970-01-13 A. N. Other <other@place>
1150 1970-01-13 A. N. Other <other@place>
1151
1151
1152 * b:
1152 * b:
1153 other 1 other 2
1153 other 1 other 2
1154
1154
1155 other 3
1155 other 3
1156 [b608e9d1a3f0]
1156 [b608e9d1a3f0]
1157
1157
1158 1970-01-12 User Name <user@hostname>
1158 1970-01-12 User Name <user@hostname>
1159
1159
1160 * a:
1160 * a:
1161 line 1 line 2
1161 line 1 line 2
1162 [1e4e1b8f71e0]
1162 [1e4e1b8f71e0]
1163
1163
1164
1164
1165 Issue2130: xml output for 'hg heads' is malformed
1165 Issue2130: xml output for 'hg heads' is malformed
1166
1166
1167 $ hg heads --style changelog
1167 $ hg heads --style changelog
1168 2020-01-01 test <test>
1168 2020-01-01 test <test>
1169
1169
1170 * fourth, second, third:
1170 * fourth, second, third:
1171 third
1171 third
1172 [95c24699272e] [tip]
1172 [95c24699272e] [tip]
1173
1173
1174 1970-01-18 person <person>
1174 1970-01-18 person <person>
1175
1175
1176 * merge
1176 * merge
1177 [d41e714fe50d]
1177 [d41e714fe50d]
1178
1178
1179 1970-01-17 person <person>
1179 1970-01-17 person <person>
1180
1180
1181 * new branch
1181 * new branch
1182 [bbe44766e73d] <foo>
1182 [bbe44766e73d] <foo>
1183
1183
1184
1184
1185 Keys work:
1185 Keys work:
1186
1186
1187 $ for key in author branch branches date desc file_adds file_dels file_mods \
1187 $ for key in author branch branches date desc file_adds file_dels file_mods \
1188 > file_copies file_copies_switch files \
1188 > file_copies file_copies_switch files \
1189 > manifest node parents rev tags diffstat extras \
1189 > manifest node parents rev tags diffstat extras \
1190 > p1rev p2rev p1node p2node; do
1190 > p1rev p2rev p1node p2node; do
1191 > for mode in '' --verbose --debug; do
1191 > for mode in '' --verbose --debug; do
1192 > hg log $mode --template "$key$mode: {$key}\n"
1192 > hg log $mode --template "$key$mode: {$key}\n"
1193 > done
1193 > done
1194 > done
1194 > done
1195 author: test
1195 author: test
1196 author: User Name <user@hostname>
1196 author: User Name <user@hostname>
1197 author: person
1197 author: person
1198 author: person
1198 author: person
1199 author: person
1199 author: person
1200 author: person
1200 author: person
1201 author: other@place
1201 author: other@place
1202 author: A. N. Other <other@place>
1202 author: A. N. Other <other@place>
1203 author: User Name <user@hostname>
1203 author: User Name <user@hostname>
1204 author--verbose: test
1204 author--verbose: test
1205 author--verbose: User Name <user@hostname>
1205 author--verbose: User Name <user@hostname>
1206 author--verbose: person
1206 author--verbose: person
1207 author--verbose: person
1207 author--verbose: person
1208 author--verbose: person
1208 author--verbose: person
1209 author--verbose: person
1209 author--verbose: person
1210 author--verbose: other@place
1210 author--verbose: other@place
1211 author--verbose: A. N. Other <other@place>
1211 author--verbose: A. N. Other <other@place>
1212 author--verbose: User Name <user@hostname>
1212 author--verbose: User Name <user@hostname>
1213 author--debug: test
1213 author--debug: test
1214 author--debug: User Name <user@hostname>
1214 author--debug: User Name <user@hostname>
1215 author--debug: person
1215 author--debug: person
1216 author--debug: person
1216 author--debug: person
1217 author--debug: person
1217 author--debug: person
1218 author--debug: person
1218 author--debug: person
1219 author--debug: other@place
1219 author--debug: other@place
1220 author--debug: A. N. Other <other@place>
1220 author--debug: A. N. Other <other@place>
1221 author--debug: User Name <user@hostname>
1221 author--debug: User Name <user@hostname>
1222 branch: default
1222 branch: default
1223 branch: default
1223 branch: default
1224 branch: default
1224 branch: default
1225 branch: default
1225 branch: default
1226 branch: foo
1226 branch: foo
1227 branch: default
1227 branch: default
1228 branch: default
1228 branch: default
1229 branch: default
1229 branch: default
1230 branch: default
1230 branch: default
1231 branch--verbose: default
1231 branch--verbose: default
1232 branch--verbose: default
1232 branch--verbose: default
1233 branch--verbose: default
1233 branch--verbose: default
1234 branch--verbose: default
1234 branch--verbose: default
1235 branch--verbose: foo
1235 branch--verbose: foo
1236 branch--verbose: default
1236 branch--verbose: default
1237 branch--verbose: default
1237 branch--verbose: default
1238 branch--verbose: default
1238 branch--verbose: default
1239 branch--verbose: default
1239 branch--verbose: default
1240 branch--debug: default
1240 branch--debug: default
1241 branch--debug: default
1241 branch--debug: default
1242 branch--debug: default
1242 branch--debug: default
1243 branch--debug: default
1243 branch--debug: default
1244 branch--debug: foo
1244 branch--debug: foo
1245 branch--debug: default
1245 branch--debug: default
1246 branch--debug: default
1246 branch--debug: default
1247 branch--debug: default
1247 branch--debug: default
1248 branch--debug: default
1248 branch--debug: default
1249 branches:
1249 branches:
1250 branches:
1250 branches:
1251 branches:
1251 branches:
1252 branches:
1252 branches:
1253 branches: foo
1253 branches: foo
1254 branches:
1254 branches:
1255 branches:
1255 branches:
1256 branches:
1256 branches:
1257 branches:
1257 branches:
1258 branches--verbose:
1258 branches--verbose:
1259 branches--verbose:
1259 branches--verbose:
1260 branches--verbose:
1260 branches--verbose:
1261 branches--verbose:
1261 branches--verbose:
1262 branches--verbose: foo
1262 branches--verbose: foo
1263 branches--verbose:
1263 branches--verbose:
1264 branches--verbose:
1264 branches--verbose:
1265 branches--verbose:
1265 branches--verbose:
1266 branches--verbose:
1266 branches--verbose:
1267 branches--debug:
1267 branches--debug:
1268 branches--debug:
1268 branches--debug:
1269 branches--debug:
1269 branches--debug:
1270 branches--debug:
1270 branches--debug:
1271 branches--debug: foo
1271 branches--debug: foo
1272 branches--debug:
1272 branches--debug:
1273 branches--debug:
1273 branches--debug:
1274 branches--debug:
1274 branches--debug:
1275 branches--debug:
1275 branches--debug:
1276 date: 1577872860.00
1276 date: 1577872860.00
1277 date: 1000000.00
1277 date: 1000000.00
1278 date: 1500001.00
1278 date: 1500001.00
1279 date: 1500000.00
1279 date: 1500000.00
1280 date: 1400000.00
1280 date: 1400000.00
1281 date: 1300000.00
1281 date: 1300000.00
1282 date: 1200000.00
1282 date: 1200000.00
1283 date: 1100000.00
1283 date: 1100000.00
1284 date: 1000000.00
1284 date: 1000000.00
1285 date--verbose: 1577872860.00
1285 date--verbose: 1577872860.00
1286 date--verbose: 1000000.00
1286 date--verbose: 1000000.00
1287 date--verbose: 1500001.00
1287 date--verbose: 1500001.00
1288 date--verbose: 1500000.00
1288 date--verbose: 1500000.00
1289 date--verbose: 1400000.00
1289 date--verbose: 1400000.00
1290 date--verbose: 1300000.00
1290 date--verbose: 1300000.00
1291 date--verbose: 1200000.00
1291 date--verbose: 1200000.00
1292 date--verbose: 1100000.00
1292 date--verbose: 1100000.00
1293 date--verbose: 1000000.00
1293 date--verbose: 1000000.00
1294 date--debug: 1577872860.00
1294 date--debug: 1577872860.00
1295 date--debug: 1000000.00
1295 date--debug: 1000000.00
1296 date--debug: 1500001.00
1296 date--debug: 1500001.00
1297 date--debug: 1500000.00
1297 date--debug: 1500000.00
1298 date--debug: 1400000.00
1298 date--debug: 1400000.00
1299 date--debug: 1300000.00
1299 date--debug: 1300000.00
1300 date--debug: 1200000.00
1300 date--debug: 1200000.00
1301 date--debug: 1100000.00
1301 date--debug: 1100000.00
1302 date--debug: 1000000.00
1302 date--debug: 1000000.00
1303 desc: third
1303 desc: third
1304 desc: second
1304 desc: second
1305 desc: merge
1305 desc: merge
1306 desc: new head
1306 desc: new head
1307 desc: new branch
1307 desc: new branch
1308 desc: no user, no domain
1308 desc: no user, no domain
1309 desc: no person
1309 desc: no person
1310 desc: other 1
1310 desc: other 1
1311 other 2
1311 other 2
1312
1312
1313 other 3
1313 other 3
1314 desc: line 1
1314 desc: line 1
1315 line 2
1315 line 2
1316 desc--verbose: third
1316 desc--verbose: third
1317 desc--verbose: second
1317 desc--verbose: second
1318 desc--verbose: merge
1318 desc--verbose: merge
1319 desc--verbose: new head
1319 desc--verbose: new head
1320 desc--verbose: new branch
1320 desc--verbose: new branch
1321 desc--verbose: no user, no domain
1321 desc--verbose: no user, no domain
1322 desc--verbose: no person
1322 desc--verbose: no person
1323 desc--verbose: other 1
1323 desc--verbose: other 1
1324 other 2
1324 other 2
1325
1325
1326 other 3
1326 other 3
1327 desc--verbose: line 1
1327 desc--verbose: line 1
1328 line 2
1328 line 2
1329 desc--debug: third
1329 desc--debug: third
1330 desc--debug: second
1330 desc--debug: second
1331 desc--debug: merge
1331 desc--debug: merge
1332 desc--debug: new head
1332 desc--debug: new head
1333 desc--debug: new branch
1333 desc--debug: new branch
1334 desc--debug: no user, no domain
1334 desc--debug: no user, no domain
1335 desc--debug: no person
1335 desc--debug: no person
1336 desc--debug: other 1
1336 desc--debug: other 1
1337 other 2
1337 other 2
1338
1338
1339 other 3
1339 other 3
1340 desc--debug: line 1
1340 desc--debug: line 1
1341 line 2
1341 line 2
1342 file_adds: fourth third
1342 file_adds: fourth third
1343 file_adds: second
1343 file_adds: second
1344 file_adds:
1344 file_adds:
1345 file_adds: d
1345 file_adds: d
1346 file_adds:
1346 file_adds:
1347 file_adds:
1347 file_adds:
1348 file_adds: c
1348 file_adds: c
1349 file_adds: b
1349 file_adds: b
1350 file_adds: a
1350 file_adds: a
1351 file_adds--verbose: fourth third
1351 file_adds--verbose: fourth third
1352 file_adds--verbose: second
1352 file_adds--verbose: second
1353 file_adds--verbose:
1353 file_adds--verbose:
1354 file_adds--verbose: d
1354 file_adds--verbose: d
1355 file_adds--verbose:
1355 file_adds--verbose:
1356 file_adds--verbose:
1356 file_adds--verbose:
1357 file_adds--verbose: c
1357 file_adds--verbose: c
1358 file_adds--verbose: b
1358 file_adds--verbose: b
1359 file_adds--verbose: a
1359 file_adds--verbose: a
1360 file_adds--debug: fourth third
1360 file_adds--debug: fourth third
1361 file_adds--debug: second
1361 file_adds--debug: second
1362 file_adds--debug:
1362 file_adds--debug:
1363 file_adds--debug: d
1363 file_adds--debug: d
1364 file_adds--debug:
1364 file_adds--debug:
1365 file_adds--debug:
1365 file_adds--debug:
1366 file_adds--debug: c
1366 file_adds--debug: c
1367 file_adds--debug: b
1367 file_adds--debug: b
1368 file_adds--debug: a
1368 file_adds--debug: a
1369 file_dels: second
1369 file_dels: second
1370 file_dels:
1370 file_dels:
1371 file_dels:
1371 file_dels:
1372 file_dels:
1372 file_dels:
1373 file_dels:
1373 file_dels:
1374 file_dels:
1374 file_dels:
1375 file_dels:
1375 file_dels:
1376 file_dels:
1376 file_dels:
1377 file_dels:
1377 file_dels:
1378 file_dels--verbose: second
1378 file_dels--verbose: second
1379 file_dels--verbose:
1379 file_dels--verbose:
1380 file_dels--verbose:
1380 file_dels--verbose:
1381 file_dels--verbose:
1381 file_dels--verbose:
1382 file_dels--verbose:
1382 file_dels--verbose:
1383 file_dels--verbose:
1383 file_dels--verbose:
1384 file_dels--verbose:
1384 file_dels--verbose:
1385 file_dels--verbose:
1385 file_dels--verbose:
1386 file_dels--verbose:
1386 file_dels--verbose:
1387 file_dels--debug: second
1387 file_dels--debug: second
1388 file_dels--debug:
1388 file_dels--debug:
1389 file_dels--debug:
1389 file_dels--debug:
1390 file_dels--debug:
1390 file_dels--debug:
1391 file_dels--debug:
1391 file_dels--debug:
1392 file_dels--debug:
1392 file_dels--debug:
1393 file_dels--debug:
1393 file_dels--debug:
1394 file_dels--debug:
1394 file_dels--debug:
1395 file_dels--debug:
1395 file_dels--debug:
1396 file_mods:
1396 file_mods:
1397 file_mods:
1397 file_mods:
1398 file_mods:
1398 file_mods:
1399 file_mods:
1399 file_mods:
1400 file_mods:
1400 file_mods:
1401 file_mods: c
1401 file_mods: c
1402 file_mods:
1402 file_mods:
1403 file_mods:
1403 file_mods:
1404 file_mods:
1404 file_mods:
1405 file_mods--verbose:
1405 file_mods--verbose:
1406 file_mods--verbose:
1406 file_mods--verbose:
1407 file_mods--verbose:
1407 file_mods--verbose:
1408 file_mods--verbose:
1408 file_mods--verbose:
1409 file_mods--verbose:
1409 file_mods--verbose:
1410 file_mods--verbose: c
1410 file_mods--verbose: c
1411 file_mods--verbose:
1411 file_mods--verbose:
1412 file_mods--verbose:
1412 file_mods--verbose:
1413 file_mods--verbose:
1413 file_mods--verbose:
1414 file_mods--debug:
1414 file_mods--debug:
1415 file_mods--debug:
1415 file_mods--debug:
1416 file_mods--debug:
1416 file_mods--debug:
1417 file_mods--debug:
1417 file_mods--debug:
1418 file_mods--debug:
1418 file_mods--debug:
1419 file_mods--debug: c
1419 file_mods--debug: c
1420 file_mods--debug:
1420 file_mods--debug:
1421 file_mods--debug:
1421 file_mods--debug:
1422 file_mods--debug:
1422 file_mods--debug:
1423 file_copies: fourth (second)
1423 file_copies: fourth (second)
1424 file_copies:
1424 file_copies:
1425 file_copies:
1425 file_copies:
1426 file_copies:
1426 file_copies:
1427 file_copies:
1427 file_copies:
1428 file_copies:
1428 file_copies:
1429 file_copies:
1429 file_copies:
1430 file_copies:
1430 file_copies:
1431 file_copies:
1431 file_copies:
1432 file_copies--verbose: fourth (second)
1432 file_copies--verbose: fourth (second)
1433 file_copies--verbose:
1433 file_copies--verbose:
1434 file_copies--verbose:
1434 file_copies--verbose:
1435 file_copies--verbose:
1435 file_copies--verbose:
1436 file_copies--verbose:
1436 file_copies--verbose:
1437 file_copies--verbose:
1437 file_copies--verbose:
1438 file_copies--verbose:
1438 file_copies--verbose:
1439 file_copies--verbose:
1439 file_copies--verbose:
1440 file_copies--verbose:
1440 file_copies--verbose:
1441 file_copies--debug: fourth (second)
1441 file_copies--debug: fourth (second)
1442 file_copies--debug:
1442 file_copies--debug:
1443 file_copies--debug:
1443 file_copies--debug:
1444 file_copies--debug:
1444 file_copies--debug:
1445 file_copies--debug:
1445 file_copies--debug:
1446 file_copies--debug:
1446 file_copies--debug:
1447 file_copies--debug:
1447 file_copies--debug:
1448 file_copies--debug:
1448 file_copies--debug:
1449 file_copies--debug:
1449 file_copies--debug:
1450 file_copies_switch:
1450 file_copies_switch:
1451 file_copies_switch:
1451 file_copies_switch:
1452 file_copies_switch:
1452 file_copies_switch:
1453 file_copies_switch:
1453 file_copies_switch:
1454 file_copies_switch:
1454 file_copies_switch:
1455 file_copies_switch:
1455 file_copies_switch:
1456 file_copies_switch:
1456 file_copies_switch:
1457 file_copies_switch:
1457 file_copies_switch:
1458 file_copies_switch:
1458 file_copies_switch:
1459 file_copies_switch--verbose:
1459 file_copies_switch--verbose:
1460 file_copies_switch--verbose:
1460 file_copies_switch--verbose:
1461 file_copies_switch--verbose:
1461 file_copies_switch--verbose:
1462 file_copies_switch--verbose:
1462 file_copies_switch--verbose:
1463 file_copies_switch--verbose:
1463 file_copies_switch--verbose:
1464 file_copies_switch--verbose:
1464 file_copies_switch--verbose:
1465 file_copies_switch--verbose:
1465 file_copies_switch--verbose:
1466 file_copies_switch--verbose:
1466 file_copies_switch--verbose:
1467 file_copies_switch--verbose:
1467 file_copies_switch--verbose:
1468 file_copies_switch--debug:
1468 file_copies_switch--debug:
1469 file_copies_switch--debug:
1469 file_copies_switch--debug:
1470 file_copies_switch--debug:
1470 file_copies_switch--debug:
1471 file_copies_switch--debug:
1471 file_copies_switch--debug:
1472 file_copies_switch--debug:
1472 file_copies_switch--debug:
1473 file_copies_switch--debug:
1473 file_copies_switch--debug:
1474 file_copies_switch--debug:
1474 file_copies_switch--debug:
1475 file_copies_switch--debug:
1475 file_copies_switch--debug:
1476 file_copies_switch--debug:
1476 file_copies_switch--debug:
1477 files: fourth second third
1477 files: fourth second third
1478 files: second
1478 files: second
1479 files:
1479 files:
1480 files: d
1480 files: d
1481 files:
1481 files:
1482 files: c
1482 files: c
1483 files: c
1483 files: c
1484 files: b
1484 files: b
1485 files: a
1485 files: a
1486 files--verbose: fourth second third
1486 files--verbose: fourth second third
1487 files--verbose: second
1487 files--verbose: second
1488 files--verbose:
1488 files--verbose:
1489 files--verbose: d
1489 files--verbose: d
1490 files--verbose:
1490 files--verbose:
1491 files--verbose: c
1491 files--verbose: c
1492 files--verbose: c
1492 files--verbose: c
1493 files--verbose: b
1493 files--verbose: b
1494 files--verbose: a
1494 files--verbose: a
1495 files--debug: fourth second third
1495 files--debug: fourth second third
1496 files--debug: second
1496 files--debug: second
1497 files--debug:
1497 files--debug:
1498 files--debug: d
1498 files--debug: d
1499 files--debug:
1499 files--debug:
1500 files--debug: c
1500 files--debug: c
1501 files--debug: c
1501 files--debug: c
1502 files--debug: b
1502 files--debug: b
1503 files--debug: a
1503 files--debug: a
1504 manifest: 6:94961b75a2da
1504 manifest: 6:94961b75a2da
1505 manifest: 5:f2dbc354b94e
1505 manifest: 5:f2dbc354b94e
1506 manifest: 4:4dc3def4f9b4
1506 manifest: 4:4dc3def4f9b4
1507 manifest: 4:4dc3def4f9b4
1507 manifest: 4:4dc3def4f9b4
1508 manifest: 3:cb5a1327723b
1508 manifest: 3:cb5a1327723b
1509 manifest: 3:cb5a1327723b
1509 manifest: 3:cb5a1327723b
1510 manifest: 2:6e0e82995c35
1510 manifest: 2:6e0e82995c35
1511 manifest: 1:4e8d705b1e53
1511 manifest: 1:4e8d705b1e53
1512 manifest: 0:a0c8bcbbb45c
1512 manifest: 0:a0c8bcbbb45c
1513 manifest--verbose: 6:94961b75a2da
1513 manifest--verbose: 6:94961b75a2da
1514 manifest--verbose: 5:f2dbc354b94e
1514 manifest--verbose: 5:f2dbc354b94e
1515 manifest--verbose: 4:4dc3def4f9b4
1515 manifest--verbose: 4:4dc3def4f9b4
1516 manifest--verbose: 4:4dc3def4f9b4
1516 manifest--verbose: 4:4dc3def4f9b4
1517 manifest--verbose: 3:cb5a1327723b
1517 manifest--verbose: 3:cb5a1327723b
1518 manifest--verbose: 3:cb5a1327723b
1518 manifest--verbose: 3:cb5a1327723b
1519 manifest--verbose: 2:6e0e82995c35
1519 manifest--verbose: 2:6e0e82995c35
1520 manifest--verbose: 1:4e8d705b1e53
1520 manifest--verbose: 1:4e8d705b1e53
1521 manifest--verbose: 0:a0c8bcbbb45c
1521 manifest--verbose: 0:a0c8bcbbb45c
1522 manifest--debug: 6:94961b75a2da554b4df6fb599e5bfc7d48de0c64
1522 manifest--debug: 6:94961b75a2da554b4df6fb599e5bfc7d48de0c64
1523 manifest--debug: 5:f2dbc354b94e5ec0b4f10680ee0cee816101d0bf
1523 manifest--debug: 5:f2dbc354b94e5ec0b4f10680ee0cee816101d0bf
1524 manifest--debug: 4:4dc3def4f9b4c6e8de820f6ee74737f91e96a216
1524 manifest--debug: 4:4dc3def4f9b4c6e8de820f6ee74737f91e96a216
1525 manifest--debug: 4:4dc3def4f9b4c6e8de820f6ee74737f91e96a216
1525 manifest--debug: 4:4dc3def4f9b4c6e8de820f6ee74737f91e96a216
1526 manifest--debug: 3:cb5a1327723bada42f117e4c55a303246eaf9ccc
1526 manifest--debug: 3:cb5a1327723bada42f117e4c55a303246eaf9ccc
1527 manifest--debug: 3:cb5a1327723bada42f117e4c55a303246eaf9ccc
1527 manifest--debug: 3:cb5a1327723bada42f117e4c55a303246eaf9ccc
1528 manifest--debug: 2:6e0e82995c35d0d57a52aca8da4e56139e06b4b1
1528 manifest--debug: 2:6e0e82995c35d0d57a52aca8da4e56139e06b4b1
1529 manifest--debug: 1:4e8d705b1e53e3f9375e0e60dc7b525d8211fe55
1529 manifest--debug: 1:4e8d705b1e53e3f9375e0e60dc7b525d8211fe55
1530 manifest--debug: 0:a0c8bcbbb45c63b90b70ad007bf38961f64f2af0
1530 manifest--debug: 0:a0c8bcbbb45c63b90b70ad007bf38961f64f2af0
1531 node: 95c24699272ef57d062b8bccc32c878bf841784a
1531 node: 95c24699272ef57d062b8bccc32c878bf841784a
1532 node: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1532 node: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1533 node: d41e714fe50d9e4a5f11b4d595d543481b5f980b
1533 node: d41e714fe50d9e4a5f11b4d595d543481b5f980b
1534 node: 13207e5a10d9fd28ec424934298e176197f2c67f
1534 node: 13207e5a10d9fd28ec424934298e176197f2c67f
1535 node: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1535 node: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1536 node: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1536 node: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1537 node: 97054abb4ab824450e9164180baf491ae0078465
1537 node: 97054abb4ab824450e9164180baf491ae0078465
1538 node: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1538 node: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1539 node: 1e4e1b8f71e05681d422154f5421e385fec3454f
1539 node: 1e4e1b8f71e05681d422154f5421e385fec3454f
1540 node--verbose: 95c24699272ef57d062b8bccc32c878bf841784a
1540 node--verbose: 95c24699272ef57d062b8bccc32c878bf841784a
1541 node--verbose: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1541 node--verbose: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1542 node--verbose: d41e714fe50d9e4a5f11b4d595d543481b5f980b
1542 node--verbose: d41e714fe50d9e4a5f11b4d595d543481b5f980b
1543 node--verbose: 13207e5a10d9fd28ec424934298e176197f2c67f
1543 node--verbose: 13207e5a10d9fd28ec424934298e176197f2c67f
1544 node--verbose: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1544 node--verbose: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1545 node--verbose: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1545 node--verbose: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1546 node--verbose: 97054abb4ab824450e9164180baf491ae0078465
1546 node--verbose: 97054abb4ab824450e9164180baf491ae0078465
1547 node--verbose: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1547 node--verbose: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1548 node--verbose: 1e4e1b8f71e05681d422154f5421e385fec3454f
1548 node--verbose: 1e4e1b8f71e05681d422154f5421e385fec3454f
1549 node--debug: 95c24699272ef57d062b8bccc32c878bf841784a
1549 node--debug: 95c24699272ef57d062b8bccc32c878bf841784a
1550 node--debug: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1550 node--debug: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1551 node--debug: d41e714fe50d9e4a5f11b4d595d543481b5f980b
1551 node--debug: d41e714fe50d9e4a5f11b4d595d543481b5f980b
1552 node--debug: 13207e5a10d9fd28ec424934298e176197f2c67f
1552 node--debug: 13207e5a10d9fd28ec424934298e176197f2c67f
1553 node--debug: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1553 node--debug: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1554 node--debug: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1554 node--debug: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1555 node--debug: 97054abb4ab824450e9164180baf491ae0078465
1555 node--debug: 97054abb4ab824450e9164180baf491ae0078465
1556 node--debug: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1556 node--debug: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1557 node--debug: 1e4e1b8f71e05681d422154f5421e385fec3454f
1557 node--debug: 1e4e1b8f71e05681d422154f5421e385fec3454f
1558 parents:
1558 parents:
1559 parents: -1:000000000000
1559 parents: -1:000000000000
1560 parents: 5:13207e5a10d9 4:bbe44766e73d
1560 parents: 5:13207e5a10d9 4:bbe44766e73d
1561 parents: 3:10e46f2dcbf4
1561 parents: 3:10e46f2dcbf4
1562 parents:
1562 parents:
1563 parents:
1563 parents:
1564 parents:
1564 parents:
1565 parents:
1565 parents:
1566 parents:
1566 parents:
1567 parents--verbose:
1567 parents--verbose:
1568 parents--verbose: -1:000000000000
1568 parents--verbose: -1:000000000000
1569 parents--verbose: 5:13207e5a10d9 4:bbe44766e73d
1569 parents--verbose: 5:13207e5a10d9 4:bbe44766e73d
1570 parents--verbose: 3:10e46f2dcbf4
1570 parents--verbose: 3:10e46f2dcbf4
1571 parents--verbose:
1571 parents--verbose:
1572 parents--verbose:
1572 parents--verbose:
1573 parents--verbose:
1573 parents--verbose:
1574 parents--verbose:
1574 parents--verbose:
1575 parents--verbose:
1575 parents--verbose:
1576 parents--debug: 7:29114dbae42b9f078cf2714dbe3a86bba8ec7453 -1:0000000000000000000000000000000000000000
1576 parents--debug: 7:29114dbae42b9f078cf2714dbe3a86bba8ec7453 -1:0000000000000000000000000000000000000000
1577 parents--debug: -1:0000000000000000000000000000000000000000 -1:0000000000000000000000000000000000000000
1577 parents--debug: -1:0000000000000000000000000000000000000000 -1:0000000000000000000000000000000000000000
1578 parents--debug: 5:13207e5a10d9fd28ec424934298e176197f2c67f 4:bbe44766e73d5f11ed2177f1838de10c53ef3e74
1578 parents--debug: 5:13207e5a10d9fd28ec424934298e176197f2c67f 4:bbe44766e73d5f11ed2177f1838de10c53ef3e74
1579 parents--debug: 3:10e46f2dcbf4823578cf180f33ecf0b957964c47 -1:0000000000000000000000000000000000000000
1579 parents--debug: 3:10e46f2dcbf4823578cf180f33ecf0b957964c47 -1:0000000000000000000000000000000000000000
1580 parents--debug: 3:10e46f2dcbf4823578cf180f33ecf0b957964c47 -1:0000000000000000000000000000000000000000
1580 parents--debug: 3:10e46f2dcbf4823578cf180f33ecf0b957964c47 -1:0000000000000000000000000000000000000000
1581 parents--debug: 2:97054abb4ab824450e9164180baf491ae0078465 -1:0000000000000000000000000000000000000000
1581 parents--debug: 2:97054abb4ab824450e9164180baf491ae0078465 -1:0000000000000000000000000000000000000000
1582 parents--debug: 1:b608e9d1a3f0273ccf70fb85fd6866b3482bf965 -1:0000000000000000000000000000000000000000
1582 parents--debug: 1:b608e9d1a3f0273ccf70fb85fd6866b3482bf965 -1:0000000000000000000000000000000000000000
1583 parents--debug: 0:1e4e1b8f71e05681d422154f5421e385fec3454f -1:0000000000000000000000000000000000000000
1583 parents--debug: 0:1e4e1b8f71e05681d422154f5421e385fec3454f -1:0000000000000000000000000000000000000000
1584 parents--debug: -1:0000000000000000000000000000000000000000 -1:0000000000000000000000000000000000000000
1584 parents--debug: -1:0000000000000000000000000000000000000000 -1:0000000000000000000000000000000000000000
1585 rev: 8
1585 rev: 8
1586 rev: 7
1586 rev: 7
1587 rev: 6
1587 rev: 6
1588 rev: 5
1588 rev: 5
1589 rev: 4
1589 rev: 4
1590 rev: 3
1590 rev: 3
1591 rev: 2
1591 rev: 2
1592 rev: 1
1592 rev: 1
1593 rev: 0
1593 rev: 0
1594 rev--verbose: 8
1594 rev--verbose: 8
1595 rev--verbose: 7
1595 rev--verbose: 7
1596 rev--verbose: 6
1596 rev--verbose: 6
1597 rev--verbose: 5
1597 rev--verbose: 5
1598 rev--verbose: 4
1598 rev--verbose: 4
1599 rev--verbose: 3
1599 rev--verbose: 3
1600 rev--verbose: 2
1600 rev--verbose: 2
1601 rev--verbose: 1
1601 rev--verbose: 1
1602 rev--verbose: 0
1602 rev--verbose: 0
1603 rev--debug: 8
1603 rev--debug: 8
1604 rev--debug: 7
1604 rev--debug: 7
1605 rev--debug: 6
1605 rev--debug: 6
1606 rev--debug: 5
1606 rev--debug: 5
1607 rev--debug: 4
1607 rev--debug: 4
1608 rev--debug: 3
1608 rev--debug: 3
1609 rev--debug: 2
1609 rev--debug: 2
1610 rev--debug: 1
1610 rev--debug: 1
1611 rev--debug: 0
1611 rev--debug: 0
1612 tags: tip
1612 tags: tip
1613 tags:
1613 tags:
1614 tags:
1614 tags:
1615 tags:
1615 tags:
1616 tags:
1616 tags:
1617 tags:
1617 tags:
1618 tags:
1618 tags:
1619 tags:
1619 tags:
1620 tags:
1620 tags:
1621 tags--verbose: tip
1621 tags--verbose: tip
1622 tags--verbose:
1622 tags--verbose:
1623 tags--verbose:
1623 tags--verbose:
1624 tags--verbose:
1624 tags--verbose:
1625 tags--verbose:
1625 tags--verbose:
1626 tags--verbose:
1626 tags--verbose:
1627 tags--verbose:
1627 tags--verbose:
1628 tags--verbose:
1628 tags--verbose:
1629 tags--verbose:
1629 tags--verbose:
1630 tags--debug: tip
1630 tags--debug: tip
1631 tags--debug:
1631 tags--debug:
1632 tags--debug:
1632 tags--debug:
1633 tags--debug:
1633 tags--debug:
1634 tags--debug:
1634 tags--debug:
1635 tags--debug:
1635 tags--debug:
1636 tags--debug:
1636 tags--debug:
1637 tags--debug:
1637 tags--debug:
1638 tags--debug:
1638 tags--debug:
1639 diffstat: 3: +2/-1
1639 diffstat: 3: +2/-1
1640 diffstat: 1: +1/-0
1640 diffstat: 1: +1/-0
1641 diffstat: 0: +0/-0
1641 diffstat: 0: +0/-0
1642 diffstat: 1: +1/-0
1642 diffstat: 1: +1/-0
1643 diffstat: 0: +0/-0
1643 diffstat: 0: +0/-0
1644 diffstat: 1: +1/-0
1644 diffstat: 1: +1/-0
1645 diffstat: 1: +4/-0
1645 diffstat: 1: +4/-0
1646 diffstat: 1: +2/-0
1646 diffstat: 1: +2/-0
1647 diffstat: 1: +1/-0
1647 diffstat: 1: +1/-0
1648 diffstat--verbose: 3: +2/-1
1648 diffstat--verbose: 3: +2/-1
1649 diffstat--verbose: 1: +1/-0
1649 diffstat--verbose: 1: +1/-0
1650 diffstat--verbose: 0: +0/-0
1650 diffstat--verbose: 0: +0/-0
1651 diffstat--verbose: 1: +1/-0
1651 diffstat--verbose: 1: +1/-0
1652 diffstat--verbose: 0: +0/-0
1652 diffstat--verbose: 0: +0/-0
1653 diffstat--verbose: 1: +1/-0
1653 diffstat--verbose: 1: +1/-0
1654 diffstat--verbose: 1: +4/-0
1654 diffstat--verbose: 1: +4/-0
1655 diffstat--verbose: 1: +2/-0
1655 diffstat--verbose: 1: +2/-0
1656 diffstat--verbose: 1: +1/-0
1656 diffstat--verbose: 1: +1/-0
1657 diffstat--debug: 3: +2/-1
1657 diffstat--debug: 3: +2/-1
1658 diffstat--debug: 1: +1/-0
1658 diffstat--debug: 1: +1/-0
1659 diffstat--debug: 0: +0/-0
1659 diffstat--debug: 0: +0/-0
1660 diffstat--debug: 1: +1/-0
1660 diffstat--debug: 1: +1/-0
1661 diffstat--debug: 0: +0/-0
1661 diffstat--debug: 0: +0/-0
1662 diffstat--debug: 1: +1/-0
1662 diffstat--debug: 1: +1/-0
1663 diffstat--debug: 1: +4/-0
1663 diffstat--debug: 1: +4/-0
1664 diffstat--debug: 1: +2/-0
1664 diffstat--debug: 1: +2/-0
1665 diffstat--debug: 1: +1/-0
1665 diffstat--debug: 1: +1/-0
1666 extras: branch=default
1666 extras: branch=default
1667 extras: branch=default
1667 extras: branch=default
1668 extras: branch=default
1668 extras: branch=default
1669 extras: branch=default
1669 extras: branch=default
1670 extras: branch=foo
1670 extras: branch=foo
1671 extras: branch=default
1671 extras: branch=default
1672 extras: branch=default
1672 extras: branch=default
1673 extras: branch=default
1673 extras: branch=default
1674 extras: branch=default
1674 extras: branch=default
1675 extras--verbose: branch=default
1675 extras--verbose: branch=default
1676 extras--verbose: branch=default
1676 extras--verbose: branch=default
1677 extras--verbose: branch=default
1677 extras--verbose: branch=default
1678 extras--verbose: branch=default
1678 extras--verbose: branch=default
1679 extras--verbose: branch=foo
1679 extras--verbose: branch=foo
1680 extras--verbose: branch=default
1680 extras--verbose: branch=default
1681 extras--verbose: branch=default
1681 extras--verbose: branch=default
1682 extras--verbose: branch=default
1682 extras--verbose: branch=default
1683 extras--verbose: branch=default
1683 extras--verbose: branch=default
1684 extras--debug: branch=default
1684 extras--debug: branch=default
1685 extras--debug: branch=default
1685 extras--debug: branch=default
1686 extras--debug: branch=default
1686 extras--debug: branch=default
1687 extras--debug: branch=default
1687 extras--debug: branch=default
1688 extras--debug: branch=foo
1688 extras--debug: branch=foo
1689 extras--debug: branch=default
1689 extras--debug: branch=default
1690 extras--debug: branch=default
1690 extras--debug: branch=default
1691 extras--debug: branch=default
1691 extras--debug: branch=default
1692 extras--debug: branch=default
1692 extras--debug: branch=default
1693 p1rev: 7
1693 p1rev: 7
1694 p1rev: -1
1694 p1rev: -1
1695 p1rev: 5
1695 p1rev: 5
1696 p1rev: 3
1696 p1rev: 3
1697 p1rev: 3
1697 p1rev: 3
1698 p1rev: 2
1698 p1rev: 2
1699 p1rev: 1
1699 p1rev: 1
1700 p1rev: 0
1700 p1rev: 0
1701 p1rev: -1
1701 p1rev: -1
1702 p1rev--verbose: 7
1702 p1rev--verbose: 7
1703 p1rev--verbose: -1
1703 p1rev--verbose: -1
1704 p1rev--verbose: 5
1704 p1rev--verbose: 5
1705 p1rev--verbose: 3
1705 p1rev--verbose: 3
1706 p1rev--verbose: 3
1706 p1rev--verbose: 3
1707 p1rev--verbose: 2
1707 p1rev--verbose: 2
1708 p1rev--verbose: 1
1708 p1rev--verbose: 1
1709 p1rev--verbose: 0
1709 p1rev--verbose: 0
1710 p1rev--verbose: -1
1710 p1rev--verbose: -1
1711 p1rev--debug: 7
1711 p1rev--debug: 7
1712 p1rev--debug: -1
1712 p1rev--debug: -1
1713 p1rev--debug: 5
1713 p1rev--debug: 5
1714 p1rev--debug: 3
1714 p1rev--debug: 3
1715 p1rev--debug: 3
1715 p1rev--debug: 3
1716 p1rev--debug: 2
1716 p1rev--debug: 2
1717 p1rev--debug: 1
1717 p1rev--debug: 1
1718 p1rev--debug: 0
1718 p1rev--debug: 0
1719 p1rev--debug: -1
1719 p1rev--debug: -1
1720 p2rev: -1
1720 p2rev: -1
1721 p2rev: -1
1721 p2rev: -1
1722 p2rev: 4
1722 p2rev: 4
1723 p2rev: -1
1723 p2rev: -1
1724 p2rev: -1
1724 p2rev: -1
1725 p2rev: -1
1725 p2rev: -1
1726 p2rev: -1
1726 p2rev: -1
1727 p2rev: -1
1727 p2rev: -1
1728 p2rev: -1
1728 p2rev: -1
1729 p2rev--verbose: -1
1729 p2rev--verbose: -1
1730 p2rev--verbose: -1
1730 p2rev--verbose: -1
1731 p2rev--verbose: 4
1731 p2rev--verbose: 4
1732 p2rev--verbose: -1
1732 p2rev--verbose: -1
1733 p2rev--verbose: -1
1733 p2rev--verbose: -1
1734 p2rev--verbose: -1
1734 p2rev--verbose: -1
1735 p2rev--verbose: -1
1735 p2rev--verbose: -1
1736 p2rev--verbose: -1
1736 p2rev--verbose: -1
1737 p2rev--verbose: -1
1737 p2rev--verbose: -1
1738 p2rev--debug: -1
1738 p2rev--debug: -1
1739 p2rev--debug: -1
1739 p2rev--debug: -1
1740 p2rev--debug: 4
1740 p2rev--debug: 4
1741 p2rev--debug: -1
1741 p2rev--debug: -1
1742 p2rev--debug: -1
1742 p2rev--debug: -1
1743 p2rev--debug: -1
1743 p2rev--debug: -1
1744 p2rev--debug: -1
1744 p2rev--debug: -1
1745 p2rev--debug: -1
1745 p2rev--debug: -1
1746 p2rev--debug: -1
1746 p2rev--debug: -1
1747 p1node: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1747 p1node: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1748 p1node: 0000000000000000000000000000000000000000
1748 p1node: 0000000000000000000000000000000000000000
1749 p1node: 13207e5a10d9fd28ec424934298e176197f2c67f
1749 p1node: 13207e5a10d9fd28ec424934298e176197f2c67f
1750 p1node: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1750 p1node: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1751 p1node: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1751 p1node: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1752 p1node: 97054abb4ab824450e9164180baf491ae0078465
1752 p1node: 97054abb4ab824450e9164180baf491ae0078465
1753 p1node: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1753 p1node: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1754 p1node: 1e4e1b8f71e05681d422154f5421e385fec3454f
1754 p1node: 1e4e1b8f71e05681d422154f5421e385fec3454f
1755 p1node: 0000000000000000000000000000000000000000
1755 p1node: 0000000000000000000000000000000000000000
1756 p1node--verbose: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1756 p1node--verbose: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1757 p1node--verbose: 0000000000000000000000000000000000000000
1757 p1node--verbose: 0000000000000000000000000000000000000000
1758 p1node--verbose: 13207e5a10d9fd28ec424934298e176197f2c67f
1758 p1node--verbose: 13207e5a10d9fd28ec424934298e176197f2c67f
1759 p1node--verbose: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1759 p1node--verbose: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1760 p1node--verbose: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1760 p1node--verbose: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1761 p1node--verbose: 97054abb4ab824450e9164180baf491ae0078465
1761 p1node--verbose: 97054abb4ab824450e9164180baf491ae0078465
1762 p1node--verbose: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1762 p1node--verbose: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1763 p1node--verbose: 1e4e1b8f71e05681d422154f5421e385fec3454f
1763 p1node--verbose: 1e4e1b8f71e05681d422154f5421e385fec3454f
1764 p1node--verbose: 0000000000000000000000000000000000000000
1764 p1node--verbose: 0000000000000000000000000000000000000000
1765 p1node--debug: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1765 p1node--debug: 29114dbae42b9f078cf2714dbe3a86bba8ec7453
1766 p1node--debug: 0000000000000000000000000000000000000000
1766 p1node--debug: 0000000000000000000000000000000000000000
1767 p1node--debug: 13207e5a10d9fd28ec424934298e176197f2c67f
1767 p1node--debug: 13207e5a10d9fd28ec424934298e176197f2c67f
1768 p1node--debug: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1768 p1node--debug: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1769 p1node--debug: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1769 p1node--debug: 10e46f2dcbf4823578cf180f33ecf0b957964c47
1770 p1node--debug: 97054abb4ab824450e9164180baf491ae0078465
1770 p1node--debug: 97054abb4ab824450e9164180baf491ae0078465
1771 p1node--debug: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1771 p1node--debug: b608e9d1a3f0273ccf70fb85fd6866b3482bf965
1772 p1node--debug: 1e4e1b8f71e05681d422154f5421e385fec3454f
1772 p1node--debug: 1e4e1b8f71e05681d422154f5421e385fec3454f
1773 p1node--debug: 0000000000000000000000000000000000000000
1773 p1node--debug: 0000000000000000000000000000000000000000
1774 p2node: 0000000000000000000000000000000000000000
1774 p2node: 0000000000000000000000000000000000000000
1775 p2node: 0000000000000000000000000000000000000000
1775 p2node: 0000000000000000000000000000000000000000
1776 p2node: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1776 p2node: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1777 p2node: 0000000000000000000000000000000000000000
1777 p2node: 0000000000000000000000000000000000000000
1778 p2node: 0000000000000000000000000000000000000000
1778 p2node: 0000000000000000000000000000000000000000
1779 p2node: 0000000000000000000000000000000000000000
1779 p2node: 0000000000000000000000000000000000000000
1780 p2node: 0000000000000000000000000000000000000000
1780 p2node: 0000000000000000000000000000000000000000
1781 p2node: 0000000000000000000000000000000000000000
1781 p2node: 0000000000000000000000000000000000000000
1782 p2node: 0000000000000000000000000000000000000000
1782 p2node: 0000000000000000000000000000000000000000
1783 p2node--verbose: 0000000000000000000000000000000000000000
1783 p2node--verbose: 0000000000000000000000000000000000000000
1784 p2node--verbose: 0000000000000000000000000000000000000000
1784 p2node--verbose: 0000000000000000000000000000000000000000
1785 p2node--verbose: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1785 p2node--verbose: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1786 p2node--verbose: 0000000000000000000000000000000000000000
1786 p2node--verbose: 0000000000000000000000000000000000000000
1787 p2node--verbose: 0000000000000000000000000000000000000000
1787 p2node--verbose: 0000000000000000000000000000000000000000
1788 p2node--verbose: 0000000000000000000000000000000000000000
1788 p2node--verbose: 0000000000000000000000000000000000000000
1789 p2node--verbose: 0000000000000000000000000000000000000000
1789 p2node--verbose: 0000000000000000000000000000000000000000
1790 p2node--verbose: 0000000000000000000000000000000000000000
1790 p2node--verbose: 0000000000000000000000000000000000000000
1791 p2node--verbose: 0000000000000000000000000000000000000000
1791 p2node--verbose: 0000000000000000000000000000000000000000
1792 p2node--debug: 0000000000000000000000000000000000000000
1792 p2node--debug: 0000000000000000000000000000000000000000
1793 p2node--debug: 0000000000000000000000000000000000000000
1793 p2node--debug: 0000000000000000000000000000000000000000
1794 p2node--debug: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1794 p2node--debug: bbe44766e73d5f11ed2177f1838de10c53ef3e74
1795 p2node--debug: 0000000000000000000000000000000000000000
1795 p2node--debug: 0000000000000000000000000000000000000000
1796 p2node--debug: 0000000000000000000000000000000000000000
1796 p2node--debug: 0000000000000000000000000000000000000000
1797 p2node--debug: 0000000000000000000000000000000000000000
1797 p2node--debug: 0000000000000000000000000000000000000000
1798 p2node--debug: 0000000000000000000000000000000000000000
1798 p2node--debug: 0000000000000000000000000000000000000000
1799 p2node--debug: 0000000000000000000000000000000000000000
1799 p2node--debug: 0000000000000000000000000000000000000000
1800 p2node--debug: 0000000000000000000000000000000000000000
1800 p2node--debug: 0000000000000000000000000000000000000000
1801
1801
1802 Filters work:
1802 Filters work:
1803
1803
1804 $ hg log --template '{author|domain}\n'
1804 $ hg log --template '{author|domain}\n'
1805
1805
1806 hostname
1806 hostname
1807
1807
1808
1808
1809
1809
1810
1810
1811 place
1811 place
1812 place
1812 place
1813 hostname
1813 hostname
1814
1814
1815 $ hg log --template '{author|person}\n'
1815 $ hg log --template '{author|person}\n'
1816 test
1816 test
1817 User Name
1817 User Name
1818 person
1818 person
1819 person
1819 person
1820 person
1820 person
1821 person
1821 person
1822 other
1822 other
1823 A. N. Other
1823 A. N. Other
1824 User Name
1824 User Name
1825
1825
1826 $ hg log --template '{author|user}\n'
1826 $ hg log --template '{author|user}\n'
1827 test
1827 test
1828 user
1828 user
1829 person
1829 person
1830 person
1830 person
1831 person
1831 person
1832 person
1832 person
1833 other
1833 other
1834 other
1834 other
1835 user
1835 user
1836
1836
1837 $ hg log --template '{date|date}\n'
1837 $ hg log --template '{date|date}\n'
1838 Wed Jan 01 10:01:00 2020 +0000
1838 Wed Jan 01 10:01:00 2020 +0000
1839 Mon Jan 12 13:46:40 1970 +0000
1839 Mon Jan 12 13:46:40 1970 +0000
1840 Sun Jan 18 08:40:01 1970 +0000
1840 Sun Jan 18 08:40:01 1970 +0000
1841 Sun Jan 18 08:40:00 1970 +0000
1841 Sun Jan 18 08:40:00 1970 +0000
1842 Sat Jan 17 04:53:20 1970 +0000
1842 Sat Jan 17 04:53:20 1970 +0000
1843 Fri Jan 16 01:06:40 1970 +0000
1843 Fri Jan 16 01:06:40 1970 +0000
1844 Wed Jan 14 21:20:00 1970 +0000
1844 Wed Jan 14 21:20:00 1970 +0000
1845 Tue Jan 13 17:33:20 1970 +0000
1845 Tue Jan 13 17:33:20 1970 +0000
1846 Mon Jan 12 13:46:40 1970 +0000
1846 Mon Jan 12 13:46:40 1970 +0000
1847
1847
1848 $ hg log --template '{date|isodate}\n'
1848 $ hg log --template '{date|isodate}\n'
1849 2020-01-01 10:01 +0000
1849 2020-01-01 10:01 +0000
1850 1970-01-12 13:46 +0000
1850 1970-01-12 13:46 +0000
1851 1970-01-18 08:40 +0000
1851 1970-01-18 08:40 +0000
1852 1970-01-18 08:40 +0000
1852 1970-01-18 08:40 +0000
1853 1970-01-17 04:53 +0000
1853 1970-01-17 04:53 +0000
1854 1970-01-16 01:06 +0000
1854 1970-01-16 01:06 +0000
1855 1970-01-14 21:20 +0000
1855 1970-01-14 21:20 +0000
1856 1970-01-13 17:33 +0000
1856 1970-01-13 17:33 +0000
1857 1970-01-12 13:46 +0000
1857 1970-01-12 13:46 +0000
1858
1858
1859 $ hg log --template '{date|isodatesec}\n'
1859 $ hg log --template '{date|isodatesec}\n'
1860 2020-01-01 10:01:00 +0000
1860 2020-01-01 10:01:00 +0000
1861 1970-01-12 13:46:40 +0000
1861 1970-01-12 13:46:40 +0000
1862 1970-01-18 08:40:01 +0000
1862 1970-01-18 08:40:01 +0000
1863 1970-01-18 08:40:00 +0000
1863 1970-01-18 08:40:00 +0000
1864 1970-01-17 04:53:20 +0000
1864 1970-01-17 04:53:20 +0000
1865 1970-01-16 01:06:40 +0000
1865 1970-01-16 01:06:40 +0000
1866 1970-01-14 21:20:00 +0000
1866 1970-01-14 21:20:00 +0000
1867 1970-01-13 17:33:20 +0000
1867 1970-01-13 17:33:20 +0000
1868 1970-01-12 13:46:40 +0000
1868 1970-01-12 13:46:40 +0000
1869
1869
1870 $ hg log --template '{date|rfc822date}\n'
1870 $ hg log --template '{date|rfc822date}\n'
1871 Wed, 01 Jan 2020 10:01:00 +0000
1871 Wed, 01 Jan 2020 10:01:00 +0000
1872 Mon, 12 Jan 1970 13:46:40 +0000
1872 Mon, 12 Jan 1970 13:46:40 +0000
1873 Sun, 18 Jan 1970 08:40:01 +0000
1873 Sun, 18 Jan 1970 08:40:01 +0000
1874 Sun, 18 Jan 1970 08:40:00 +0000
1874 Sun, 18 Jan 1970 08:40:00 +0000
1875 Sat, 17 Jan 1970 04:53:20 +0000
1875 Sat, 17 Jan 1970 04:53:20 +0000
1876 Fri, 16 Jan 1970 01:06:40 +0000
1876 Fri, 16 Jan 1970 01:06:40 +0000
1877 Wed, 14 Jan 1970 21:20:00 +0000
1877 Wed, 14 Jan 1970 21:20:00 +0000
1878 Tue, 13 Jan 1970 17:33:20 +0000
1878 Tue, 13 Jan 1970 17:33:20 +0000
1879 Mon, 12 Jan 1970 13:46:40 +0000
1879 Mon, 12 Jan 1970 13:46:40 +0000
1880
1880
1881 $ hg log --template '{desc|firstline}\n'
1881 $ hg log --template '{desc|firstline}\n'
1882 third
1882 third
1883 second
1883 second
1884 merge
1884 merge
1885 new head
1885 new head
1886 new branch
1886 new branch
1887 no user, no domain
1887 no user, no domain
1888 no person
1888 no person
1889 other 1
1889 other 1
1890 line 1
1890 line 1
1891
1891
1892 $ hg log --template '{node|short}\n'
1892 $ hg log --template '{node|short}\n'
1893 95c24699272e
1893 95c24699272e
1894 29114dbae42b
1894 29114dbae42b
1895 d41e714fe50d
1895 d41e714fe50d
1896 13207e5a10d9
1896 13207e5a10d9
1897 bbe44766e73d
1897 bbe44766e73d
1898 10e46f2dcbf4
1898 10e46f2dcbf4
1899 97054abb4ab8
1899 97054abb4ab8
1900 b608e9d1a3f0
1900 b608e9d1a3f0
1901 1e4e1b8f71e0
1901 1e4e1b8f71e0
1902
1902
1903 $ hg log --template '<changeset author="{author|xmlescape}"/>\n'
1903 $ hg log --template '<changeset author="{author|xmlescape}"/>\n'
1904 <changeset author="test"/>
1904 <changeset author="test"/>
1905 <changeset author="User Name &lt;user@hostname&gt;"/>
1905 <changeset author="User Name &lt;user@hostname&gt;"/>
1906 <changeset author="person"/>
1906 <changeset author="person"/>
1907 <changeset author="person"/>
1907 <changeset author="person"/>
1908 <changeset author="person"/>
1908 <changeset author="person"/>
1909 <changeset author="person"/>
1909 <changeset author="person"/>
1910 <changeset author="other@place"/>
1910 <changeset author="other@place"/>
1911 <changeset author="A. N. Other &lt;other@place&gt;"/>
1911 <changeset author="A. N. Other &lt;other@place&gt;"/>
1912 <changeset author="User Name &lt;user@hostname&gt;"/>
1912 <changeset author="User Name &lt;user@hostname&gt;"/>
1913
1913
1914 $ hg log --template '{rev}: {children}\n'
1914 $ hg log --template '{rev}: {children}\n'
1915 8:
1915 8:
1916 7: 8:95c24699272e
1916 7: 8:95c24699272e
1917 6:
1917 6:
1918 5: 6:d41e714fe50d
1918 5: 6:d41e714fe50d
1919 4: 6:d41e714fe50d
1919 4: 6:d41e714fe50d
1920 3: 4:bbe44766e73d 5:13207e5a10d9
1920 3: 4:bbe44766e73d 5:13207e5a10d9
1921 2: 3:10e46f2dcbf4
1921 2: 3:10e46f2dcbf4
1922 1: 2:97054abb4ab8
1922 1: 2:97054abb4ab8
1923 0: 1:b608e9d1a3f0
1923 0: 1:b608e9d1a3f0
1924
1924
1925 Formatnode filter works:
1925 Formatnode filter works:
1926
1926
1927 $ hg -q log -r 0 --template '{node|formatnode}\n'
1927 $ hg -q log -r 0 --template '{node|formatnode}\n'
1928 1e4e1b8f71e0
1928 1e4e1b8f71e0
1929
1929
1930 $ hg log -r 0 --template '{node|formatnode}\n'
1930 $ hg log -r 0 --template '{node|formatnode}\n'
1931 1e4e1b8f71e0
1931 1e4e1b8f71e0
1932
1932
1933 $ hg -v log -r 0 --template '{node|formatnode}\n'
1933 $ hg -v log -r 0 --template '{node|formatnode}\n'
1934 1e4e1b8f71e0
1934 1e4e1b8f71e0
1935
1935
1936 $ hg --debug log -r 0 --template '{node|formatnode}\n'
1936 $ hg --debug log -r 0 --template '{node|formatnode}\n'
1937 1e4e1b8f71e05681d422154f5421e385fec3454f
1937 1e4e1b8f71e05681d422154f5421e385fec3454f
1938
1938
1939 Age filter:
1939 Age filter:
1940
1940
1941 $ hg init unstable-hash
1941 $ hg init unstable-hash
1942 $ cd unstable-hash
1942 $ cd unstable-hash
1943 $ hg log --template '{date|age}\n' > /dev/null || exit 1
1943 $ hg log --template '{date|age}\n' > /dev/null || exit 1
1944
1944
1945 >>> from datetime import datetime, timedelta
1945 >>> from datetime import datetime, timedelta
1946 >>> fp = open('a', 'w')
1946 >>> fp = open('a', 'w')
1947 >>> n = datetime.now() + timedelta(366 * 7)
1947 >>> n = datetime.now() + timedelta(366 * 7)
1948 >>> fp.write('%d-%d-%d 00:00' % (n.year, n.month, n.day))
1948 >>> fp.write('%d-%d-%d 00:00' % (n.year, n.month, n.day))
1949 >>> fp.close()
1949 >>> fp.close()
1950 $ hg add a
1950 $ hg add a
1951 $ hg commit -m future -d "`cat a`"
1951 $ hg commit -m future -d "`cat a`"
1952
1952
1953 $ hg log -l1 --template '{date|age}\n'
1953 $ hg log -l1 --template '{date|age}\n'
1954 7 years from now
1954 7 years from now
1955
1955
1956 $ cd ..
1956 $ cd ..
1957 $ rm -rf unstable-hash
1957 $ rm -rf unstable-hash
1958
1958
1959 Add a dummy commit to make up for the instability of the above:
1959 Add a dummy commit to make up for the instability of the above:
1960
1960
1961 $ echo a > a
1961 $ echo a > a
1962 $ hg add a
1962 $ hg add a
1963 $ hg ci -m future
1963 $ hg ci -m future
1964
1964
1965 Count filter:
1965 Count filter:
1966
1966
1967 $ hg log -l1 --template '{node|count} {node|short|count}\n'
1967 $ hg log -l1 --template '{node|count} {node|short|count}\n'
1968 40 12
1968 40 12
1969
1969
1970 $ hg log -l1 --template '{revset("null^")|count} {revset(".")|count} {revset("0::3")|count}\n'
1970 $ hg log -l1 --template '{revset("null^")|count} {revset(".")|count} {revset("0::3")|count}\n'
1971 0 1 4
1971 0 1 4
1972
1972
1973 $ hg log -G --template '{rev}: children: {children|count}, \
1973 $ hg log -G --template '{rev}: children: {children|count}, \
1974 > tags: {tags|count}, file_adds: {file_adds|count}, \
1974 > tags: {tags|count}, file_adds: {file_adds|count}, \
1975 > ancestors: {revset("ancestors(%s)", rev)|count}'
1975 > ancestors: {revset("ancestors(%s)", rev)|count}'
1976 @ 9: children: 0, tags: 1, file_adds: 1, ancestors: 3
1976 @ 9: children: 0, tags: 1, file_adds: 1, ancestors: 3
1977 |
1977 |
1978 o 8: children: 1, tags: 0, file_adds: 2, ancestors: 2
1978 o 8: children: 1, tags: 0, file_adds: 2, ancestors: 2
1979 |
1979 |
1980 o 7: children: 1, tags: 0, file_adds: 1, ancestors: 1
1980 o 7: children: 1, tags: 0, file_adds: 1, ancestors: 1
1981
1981
1982 o 6: children: 0, tags: 0, file_adds: 0, ancestors: 7
1982 o 6: children: 0, tags: 0, file_adds: 0, ancestors: 7
1983 |\
1983 |\
1984 | o 5: children: 1, tags: 0, file_adds: 1, ancestors: 5
1984 | o 5: children: 1, tags: 0, file_adds: 1, ancestors: 5
1985 | |
1985 | |
1986 o | 4: children: 1, tags: 0, file_adds: 0, ancestors: 5
1986 o | 4: children: 1, tags: 0, file_adds: 0, ancestors: 5
1987 |/
1987 |/
1988 o 3: children: 2, tags: 0, file_adds: 0, ancestors: 4
1988 o 3: children: 2, tags: 0, file_adds: 0, ancestors: 4
1989 |
1989 |
1990 o 2: children: 1, tags: 0, file_adds: 1, ancestors: 3
1990 o 2: children: 1, tags: 0, file_adds: 1, ancestors: 3
1991 |
1991 |
1992 o 1: children: 1, tags: 0, file_adds: 1, ancestors: 2
1992 o 1: children: 1, tags: 0, file_adds: 1, ancestors: 2
1993 |
1993 |
1994 o 0: children: 1, tags: 0, file_adds: 1, ancestors: 1
1994 o 0: children: 1, tags: 0, file_adds: 1, ancestors: 1
1995
1995
1996
1996
1997 Upper/lower filters:
1997 Upper/lower filters:
1998
1998
1999 $ hg log -r0 --template '{branch|upper}\n'
1999 $ hg log -r0 --template '{branch|upper}\n'
2000 DEFAULT
2000 DEFAULT
2001 $ hg log -r0 --template '{author|lower}\n'
2001 $ hg log -r0 --template '{author|lower}\n'
2002 user name <user@hostname>
2002 user name <user@hostname>
2003 $ hg log -r0 --template '{date|upper}\n'
2003 $ hg log -r0 --template '{date|upper}\n'
2004 abort: template filter 'upper' is not compatible with keyword 'date'
2004 abort: template filter 'upper' is not compatible with keyword 'date'
2005 [255]
2005 [255]
2006
2006
2007 Add a commit that does all possible modifications at once
2007 Add a commit that does all possible modifications at once
2008
2008
2009 $ echo modify >> third
2009 $ echo modify >> third
2010 $ touch b
2010 $ touch b
2011 $ hg add b
2011 $ hg add b
2012 $ hg mv fourth fifth
2012 $ hg mv fourth fifth
2013 $ hg rm a
2013 $ hg rm a
2014 $ hg ci -m "Modify, add, remove, rename"
2014 $ hg ci -m "Modify, add, remove, rename"
2015
2015
2016 Check the status template
2017
2018 $ cat <<EOF >> $HGRCPATH
2019 > [extensions]
2020 > color=
2021 > EOF
2022
2023 $ hg log -T status -r 10
2024 changeset: 10:0f9759ec227a
2025 tag: tip
2026 user: test
2027 date: Thu Jan 01 00:00:00 1970 +0000
2028 summary: Modify, add, remove, rename
2029 files:
2030 M third
2031 A b
2032 A fifth
2033 R a
2034 R fourth
2035
2036 $ hg log -T status -C -r 10
2037 changeset: 10:0f9759ec227a
2038 tag: tip
2039 user: test
2040 date: Thu Jan 01 00:00:00 1970 +0000
2041 summary: Modify, add, remove, rename
2042 files:
2043 M third
2044 A b
2045 A fifth
2046 fourth
2047 R a
2048 R fourth
2049
2050 $ hg log -T status -C -r 10 -v
2051 changeset: 10:0f9759ec227a
2052 tag: tip
2053 user: test
2054 date: Thu Jan 01 00:00:00 1970 +0000
2055 description:
2056 Modify, add, remove, rename
2057
2058 files:
2059 M third
2060 A b
2061 A fifth
2062 fourth
2063 R a
2064 R fourth
2065
2066 $ hg log -T status -C -r 10 --debug
2067 changeset: 10:0f9759ec227a4859c2014a345cd8a859022b7c6c
2068 tag: tip
2069 phase: secret
2070 parent: 9:bf9dfba36635106d6a73ccc01e28b762da60e066
2071 parent: -1:0000000000000000000000000000000000000000
2072 manifest: 8:89dd546f2de0a9d6d664f58d86097eb97baba567
2073 user: test
2074 date: Thu Jan 01 00:00:00 1970 +0000
2075 extra: branch=default
2076 description:
2077 Modify, add, remove, rename
2078
2079 files:
2080 M third
2081 A b
2082 A fifth
2083 fourth
2084 R a
2085 R fourth
2086
2087 $ hg log -T status -C -r 10 --quiet
2088 10:0f9759ec227a
2089 $ hg --color=debug log -T status -r 10
2090 [log.changeset changeset.secret|changeset: 10:0f9759ec227a]
2091 [log.tag|tag: tip]
2092 [log.user|user: test]
2093 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
2094 [log.summary|summary: Modify, add, remove, rename]
2095 [ui.note log.files|files:]
2096 [status.modified|M third]
2097 [status.added|A b]
2098 [status.added|A fifth]
2099 [status.removed|R a]
2100 [status.removed|R fourth]
2101
2102 $ hg --color=debug log -T status -C -r 10
2103 [log.changeset changeset.secret|changeset: 10:0f9759ec227a]
2104 [log.tag|tag: tip]
2105 [log.user|user: test]
2106 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
2107 [log.summary|summary: Modify, add, remove, rename]
2108 [ui.note log.files|files:]
2109 [status.modified|M third]
2110 [status.added|A b]
2111 [status.added|A fifth]
2112 [status.copied| fourth]
2113 [status.removed|R a]
2114 [status.removed|R fourth]
2115
2116 $ hg --color=debug log -T status -C -r 10 -v
2117 [log.changeset changeset.secret|changeset: 10:0f9759ec227a]
2118 [log.tag|tag: tip]
2119 [log.user|user: test]
2120 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
2121 [ui.note log.description|description:]
2122 [ui.note log.description|Modify, add, remove, rename]
2123
2124 [ui.note log.files|files:]
2125 [status.modified|M third]
2126 [status.added|A b]
2127 [status.added|A fifth]
2128 [status.copied| fourth]
2129 [status.removed|R a]
2130 [status.removed|R fourth]
2131
2132 $ hg --color=debug log -T status -C -r 10 --debug
2133 [log.changeset changeset.secret|changeset: 10:0f9759ec227a4859c2014a345cd8a859022b7c6c]
2134 [log.tag|tag: tip]
2135 [log.phase|phase: secret]
2136 [log.parent changeset.secret|parent: 9:bf9dfba36635106d6a73ccc01e28b762da60e066]
2137 [log.parent changeset.public|parent: -1:0000000000000000000000000000000000000000]
2138 [ui.debug log.manifest|manifest: 8:89dd546f2de0a9d6d664f58d86097eb97baba567]
2139 [log.user|user: test]
2140 [log.date|date: Thu Jan 01 00:00:00 1970 +0000]
2141 [ui.debug log.extra|extra: branch=default]
2142 [ui.note log.description|description:]
2143 [ui.note log.description|Modify, add, remove, rename]
2144
2145 [ui.note log.files|files:]
2146 [status.modified|M third]
2147 [status.added|A b]
2148 [status.added|A fifth]
2149 [status.copied| fourth]
2150 [status.removed|R a]
2151 [status.removed|R fourth]
2152
2153 $ hg --color=debug log -T status -C -r 10 --quiet
2154 [log.node|10:0f9759ec227a]
2155
2156
2016 Error on syntax:
2157 Error on syntax:
2017
2158
2018 $ echo 'x = "f' >> t
2159 $ echo 'x = "f' >> t
2019 $ hg log
2160 $ hg log
2020 abort: t:3: unmatched quotes
2161 abort: t:3: unmatched quotes
2021 [255]
2162 [255]
2022
2163
2023 Behind the scenes, this will throw TypeError
2164 Behind the scenes, this will throw TypeError
2024
2165
2025 $ hg log -l 3 --template '{date|obfuscate}\n'
2166 $ hg log -l 3 --template '{date|obfuscate}\n'
2026 abort: template filter 'obfuscate' is not compatible with keyword 'date'
2167 abort: template filter 'obfuscate' is not compatible with keyword 'date'
2027 [255]
2168 [255]
2028
2169
2029 Behind the scenes, this will throw a ValueError
2170 Behind the scenes, this will throw a ValueError
2030
2171
2031 $ hg log -l 3 --template 'line: {desc|shortdate}\n'
2172 $ hg log -l 3 --template 'line: {desc|shortdate}\n'
2032 abort: template filter 'shortdate' is not compatible with keyword 'desc'
2173 abort: template filter 'shortdate' is not compatible with keyword 'desc'
2033 [255]
2174 [255]
2034
2175
2035 Behind the scenes, this will throw AttributeError
2176 Behind the scenes, this will throw AttributeError
2036
2177
2037 $ hg log -l 3 --template 'line: {date|escape}\n'
2178 $ hg log -l 3 --template 'line: {date|escape}\n'
2038 abort: template filter 'escape' is not compatible with keyword 'date'
2179 abort: template filter 'escape' is not compatible with keyword 'date'
2039 [255]
2180 [255]
2040
2181
2041 Behind the scenes, this will throw ValueError
2182 Behind the scenes, this will throw ValueError
2042
2183
2043 $ hg tip --template '{author|email|date}\n'
2184 $ hg tip --template '{author|email|date}\n'
2044 abort: template filter 'datefilter' is not compatible with keyword 'author'
2185 abort: template filter 'datefilter' is not compatible with keyword 'author'
2045 [255]
2186 [255]
2046
2187
2047 Thrown an error if a template function doesn't exist
2188 Thrown an error if a template function doesn't exist
2048
2189
2049 $ hg tip --template '{foo()}\n'
2190 $ hg tip --template '{foo()}\n'
2050 hg: parse error: unknown function 'foo'
2191 hg: parse error: unknown function 'foo'
2051 [255]
2192 [255]
2052
2193
2053 Pass generator object created by template function to filter
2194 Pass generator object created by template function to filter
2054
2195
2055 $ hg log -l 1 --template '{if(author, author)|user}\n'
2196 $ hg log -l 1 --template '{if(author, author)|user}\n'
2056 test
2197 test
2057
2198
2058 Test diff function:
2199 Test diff function:
2059
2200
2060 $ hg diff -c 8
2201 $ hg diff -c 8
2061 diff -r 29114dbae42b -r 95c24699272e fourth
2202 diff -r 29114dbae42b -r 95c24699272e fourth
2062 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2203 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2063 +++ b/fourth Wed Jan 01 10:01:00 2020 +0000
2204 +++ b/fourth Wed Jan 01 10:01:00 2020 +0000
2064 @@ -0,0 +1,1 @@
2205 @@ -0,0 +1,1 @@
2065 +second
2206 +second
2066 diff -r 29114dbae42b -r 95c24699272e second
2207 diff -r 29114dbae42b -r 95c24699272e second
2067 --- a/second Mon Jan 12 13:46:40 1970 +0000
2208 --- a/second Mon Jan 12 13:46:40 1970 +0000
2068 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
2209 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
2069 @@ -1,1 +0,0 @@
2210 @@ -1,1 +0,0 @@
2070 -second
2211 -second
2071 diff -r 29114dbae42b -r 95c24699272e third
2212 diff -r 29114dbae42b -r 95c24699272e third
2072 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2213 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2073 +++ b/third Wed Jan 01 10:01:00 2020 +0000
2214 +++ b/third Wed Jan 01 10:01:00 2020 +0000
2074 @@ -0,0 +1,1 @@
2215 @@ -0,0 +1,1 @@
2075 +third
2216 +third
2076
2217
2077 $ hg log -r 8 -T "{diff()}"
2218 $ hg log -r 8 -T "{diff()}"
2078 diff -r 29114dbae42b -r 95c24699272e fourth
2219 diff -r 29114dbae42b -r 95c24699272e fourth
2079 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2220 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2080 +++ b/fourth Wed Jan 01 10:01:00 2020 +0000
2221 +++ b/fourth Wed Jan 01 10:01:00 2020 +0000
2081 @@ -0,0 +1,1 @@
2222 @@ -0,0 +1,1 @@
2082 +second
2223 +second
2083 diff -r 29114dbae42b -r 95c24699272e second
2224 diff -r 29114dbae42b -r 95c24699272e second
2084 --- a/second Mon Jan 12 13:46:40 1970 +0000
2225 --- a/second Mon Jan 12 13:46:40 1970 +0000
2085 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
2226 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
2086 @@ -1,1 +0,0 @@
2227 @@ -1,1 +0,0 @@
2087 -second
2228 -second
2088 diff -r 29114dbae42b -r 95c24699272e third
2229 diff -r 29114dbae42b -r 95c24699272e third
2089 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2230 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2090 +++ b/third Wed Jan 01 10:01:00 2020 +0000
2231 +++ b/third Wed Jan 01 10:01:00 2020 +0000
2091 @@ -0,0 +1,1 @@
2232 @@ -0,0 +1,1 @@
2092 +third
2233 +third
2093
2234
2094 $ hg log -r 8 -T "{diff('glob:f*')}"
2235 $ hg log -r 8 -T "{diff('glob:f*')}"
2095 diff -r 29114dbae42b -r 95c24699272e fourth
2236 diff -r 29114dbae42b -r 95c24699272e fourth
2096 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2237 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2097 +++ b/fourth Wed Jan 01 10:01:00 2020 +0000
2238 +++ b/fourth Wed Jan 01 10:01:00 2020 +0000
2098 @@ -0,0 +1,1 @@
2239 @@ -0,0 +1,1 @@
2099 +second
2240 +second
2100
2241
2101 $ hg log -r 8 -T "{diff('', 'glob:f*')}"
2242 $ hg log -r 8 -T "{diff('', 'glob:f*')}"
2102 diff -r 29114dbae42b -r 95c24699272e second
2243 diff -r 29114dbae42b -r 95c24699272e second
2103 --- a/second Mon Jan 12 13:46:40 1970 +0000
2244 --- a/second Mon Jan 12 13:46:40 1970 +0000
2104 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
2245 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
2105 @@ -1,1 +0,0 @@
2246 @@ -1,1 +0,0 @@
2106 -second
2247 -second
2107 diff -r 29114dbae42b -r 95c24699272e third
2248 diff -r 29114dbae42b -r 95c24699272e third
2108 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2249 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2109 +++ b/third Wed Jan 01 10:01:00 2020 +0000
2250 +++ b/third Wed Jan 01 10:01:00 2020 +0000
2110 @@ -0,0 +1,1 @@
2251 @@ -0,0 +1,1 @@
2111 +third
2252 +third
2112
2253
2113 $ cd ..
2254 $ cd ..
2114
2255
2115
2256
2116 latesttag:
2257 latesttag:
2117
2258
2118 $ hg init latesttag
2259 $ hg init latesttag
2119 $ cd latesttag
2260 $ cd latesttag
2120
2261
2121 $ echo a > file
2262 $ echo a > file
2122 $ hg ci -Am a -d '0 0'
2263 $ hg ci -Am a -d '0 0'
2123 adding file
2264 adding file
2124
2265
2125 $ echo b >> file
2266 $ echo b >> file
2126 $ hg ci -m b -d '1 0'
2267 $ hg ci -m b -d '1 0'
2127
2268
2128 $ echo c >> head1
2269 $ echo c >> head1
2129 $ hg ci -Am h1c -d '2 0'
2270 $ hg ci -Am h1c -d '2 0'
2130 adding head1
2271 adding head1
2131
2272
2132 $ hg update -q 1
2273 $ hg update -q 1
2133 $ echo d >> head2
2274 $ echo d >> head2
2134 $ hg ci -Am h2d -d '3 0'
2275 $ hg ci -Am h2d -d '3 0'
2135 adding head2
2276 adding head2
2136 created new head
2277 created new head
2137
2278
2138 $ echo e >> head2
2279 $ echo e >> head2
2139 $ hg ci -m h2e -d '4 0'
2280 $ hg ci -m h2e -d '4 0'
2140
2281
2141 $ hg merge -q
2282 $ hg merge -q
2142 $ hg ci -m merge -d '5 -3600'
2283 $ hg ci -m merge -d '5 -3600'
2143
2284
2144 No tag set:
2285 No tag set:
2145
2286
2146 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2287 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2147 5: null+5
2288 5: null+5
2148 4: null+4
2289 4: null+4
2149 3: null+3
2290 3: null+3
2150 2: null+3
2291 2: null+3
2151 1: null+2
2292 1: null+2
2152 0: null+1
2293 0: null+1
2153
2294
2154 One common tag: longest path wins:
2295 One common tag: longest path wins:
2155
2296
2156 $ hg tag -r 1 -m t1 -d '6 0' t1
2297 $ hg tag -r 1 -m t1 -d '6 0' t1
2157 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2298 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2158 6: t1+4
2299 6: t1+4
2159 5: t1+3
2300 5: t1+3
2160 4: t1+2
2301 4: t1+2
2161 3: t1+1
2302 3: t1+1
2162 2: t1+1
2303 2: t1+1
2163 1: t1+0
2304 1: t1+0
2164 0: null+1
2305 0: null+1
2165
2306
2166 One ancestor tag: more recent wins:
2307 One ancestor tag: more recent wins:
2167
2308
2168 $ hg tag -r 2 -m t2 -d '7 0' t2
2309 $ hg tag -r 2 -m t2 -d '7 0' t2
2169 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2310 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2170 7: t2+3
2311 7: t2+3
2171 6: t2+2
2312 6: t2+2
2172 5: t2+1
2313 5: t2+1
2173 4: t1+2
2314 4: t1+2
2174 3: t1+1
2315 3: t1+1
2175 2: t2+0
2316 2: t2+0
2176 1: t1+0
2317 1: t1+0
2177 0: null+1
2318 0: null+1
2178
2319
2179 Two branch tags: more recent wins:
2320 Two branch tags: more recent wins:
2180
2321
2181 $ hg tag -r 3 -m t3 -d '8 0' t3
2322 $ hg tag -r 3 -m t3 -d '8 0' t3
2182 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2323 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2183 8: t3+5
2324 8: t3+5
2184 7: t3+4
2325 7: t3+4
2185 6: t3+3
2326 6: t3+3
2186 5: t3+2
2327 5: t3+2
2187 4: t3+1
2328 4: t3+1
2188 3: t3+0
2329 3: t3+0
2189 2: t2+0
2330 2: t2+0
2190 1: t1+0
2331 1: t1+0
2191 0: null+1
2332 0: null+1
2192
2333
2193 Merged tag overrides:
2334 Merged tag overrides:
2194
2335
2195 $ hg tag -r 5 -m t5 -d '9 0' t5
2336 $ hg tag -r 5 -m t5 -d '9 0' t5
2196 $ hg tag -r 3 -m at3 -d '10 0' at3
2337 $ hg tag -r 3 -m at3 -d '10 0' at3
2197 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2338 $ hg log --template '{rev}: {latesttag}+{latesttagdistance}\n'
2198 10: t5+5
2339 10: t5+5
2199 9: t5+4
2340 9: t5+4
2200 8: t5+3
2341 8: t5+3
2201 7: t5+2
2342 7: t5+2
2202 6: t5+1
2343 6: t5+1
2203 5: t5+0
2344 5: t5+0
2204 4: at3:t3+1
2345 4: at3:t3+1
2205 3: at3:t3+0
2346 3: at3:t3+0
2206 2: t2+0
2347 2: t2+0
2207 1: t1+0
2348 1: t1+0
2208 0: null+1
2349 0: null+1
2209
2350
2210 $ cd ..
2351 $ cd ..
2211
2352
2212
2353
2213 Style path expansion: issue1948 - ui.style option doesn't work on OSX
2354 Style path expansion: issue1948 - ui.style option doesn't work on OSX
2214 if it is a relative path
2355 if it is a relative path
2215
2356
2216 $ mkdir -p home/styles
2357 $ mkdir -p home/styles
2217
2358
2218 $ cat > home/styles/teststyle <<EOF
2359 $ cat > home/styles/teststyle <<EOF
2219 > changeset = 'test {rev}:{node|short}\n'
2360 > changeset = 'test {rev}:{node|short}\n'
2220 > EOF
2361 > EOF
2221
2362
2222 $ HOME=`pwd`/home; export HOME
2363 $ HOME=`pwd`/home; export HOME
2223
2364
2224 $ cat > latesttag/.hg/hgrc <<EOF
2365 $ cat > latesttag/.hg/hgrc <<EOF
2225 > [ui]
2366 > [ui]
2226 > style = ~/styles/teststyle
2367 > style = ~/styles/teststyle
2227 > EOF
2368 > EOF
2228
2369
2229 $ hg -R latesttag tip
2370 $ hg -R latesttag tip
2230 test 10:9b4a630e5f5f
2371 test 10:9b4a630e5f5f
2231
2372
2232 Test recursive showlist template (issue1989):
2373 Test recursive showlist template (issue1989):
2233
2374
2234 $ cat > style1989 <<EOF
2375 $ cat > style1989 <<EOF
2235 > changeset = '{file_mods}{manifest}{extras}'
2376 > changeset = '{file_mods}{manifest}{extras}'
2236 > file_mod = 'M|{author|person}\n'
2377 > file_mod = 'M|{author|person}\n'
2237 > manifest = '{rev},{author}\n'
2378 > manifest = '{rev},{author}\n'
2238 > extra = '{key}: {author}\n'
2379 > extra = '{key}: {author}\n'
2239 > EOF
2380 > EOF
2240
2381
2241 $ hg -R latesttag log -r tip --style=style1989
2382 $ hg -R latesttag log -r tip --style=style1989
2242 M|test
2383 M|test
2243 10,test
2384 10,test
2244 branch: test
2385 branch: test
2245
2386
2246 Test new-style inline templating:
2387 Test new-style inline templating:
2247
2388
2248 $ hg log -R latesttag -r tip --template 'modified files: {file_mods % " {file}\n"}\n'
2389 $ hg log -R latesttag -r tip --template 'modified files: {file_mods % " {file}\n"}\n'
2249 modified files: .hgtags
2390 modified files: .hgtags
2250
2391
2251 Test the sub function of templating for expansion:
2392 Test the sub function of templating for expansion:
2252
2393
2253 $ hg log -R latesttag -r 10 --template '{sub("[0-9]", "x", "{rev}")}\n'
2394 $ hg log -R latesttag -r 10 --template '{sub("[0-9]", "x", "{rev}")}\n'
2254 xx
2395 xx
2255
2396
2256 Test the strip function with chars specified:
2397 Test the strip function with chars specified:
2257
2398
2258 $ hg log -R latesttag --template '{desc}\n'
2399 $ hg log -R latesttag --template '{desc}\n'
2259 at3
2400 at3
2260 t5
2401 t5
2261 t3
2402 t3
2262 t2
2403 t2
2263 t1
2404 t1
2264 merge
2405 merge
2265 h2e
2406 h2e
2266 h2d
2407 h2d
2267 h1c
2408 h1c
2268 b
2409 b
2269 a
2410 a
2270
2411
2271 $ hg log -R latesttag --template '{strip(desc, "te")}\n'
2412 $ hg log -R latesttag --template '{strip(desc, "te")}\n'
2272 at3
2413 at3
2273 5
2414 5
2274 3
2415 3
2275 2
2416 2
2276 1
2417 1
2277 merg
2418 merg
2278 h2
2419 h2
2279 h2d
2420 h2d
2280 h1c
2421 h1c
2281 b
2422 b
2282 a
2423 a
2283
2424
2284 Test date format:
2425 Test date format:
2285
2426
2286 $ hg log -R latesttag --template 'date: {date(date, "%y %m %d %S %z")}\n'
2427 $ hg log -R latesttag --template 'date: {date(date, "%y %m %d %S %z")}\n'
2287 date: 70 01 01 10 +0000
2428 date: 70 01 01 10 +0000
2288 date: 70 01 01 09 +0000
2429 date: 70 01 01 09 +0000
2289 date: 70 01 01 08 +0000
2430 date: 70 01 01 08 +0000
2290 date: 70 01 01 07 +0000
2431 date: 70 01 01 07 +0000
2291 date: 70 01 01 06 +0000
2432 date: 70 01 01 06 +0000
2292 date: 70 01 01 05 +0100
2433 date: 70 01 01 05 +0100
2293 date: 70 01 01 04 +0000
2434 date: 70 01 01 04 +0000
2294 date: 70 01 01 03 +0000
2435 date: 70 01 01 03 +0000
2295 date: 70 01 01 02 +0000
2436 date: 70 01 01 02 +0000
2296 date: 70 01 01 01 +0000
2437 date: 70 01 01 01 +0000
2297 date: 70 01 01 00 +0000
2438 date: 70 01 01 00 +0000
2298
2439
2299 Test invalid date:
2440 Test invalid date:
2300
2441
2301 $ hg log -R latesttag -T '{date(rev)}\n'
2442 $ hg log -R latesttag -T '{date(rev)}\n'
2302 hg: parse error: date expects a date information
2443 hg: parse error: date expects a date information
2303 [255]
2444 [255]
2304
2445
2305 Test integer literal:
2446 Test integer literal:
2306
2447
2307 $ hg log -Ra -r0 -T '{(0)}\n'
2448 $ hg log -Ra -r0 -T '{(0)}\n'
2308 0
2449 0
2309 $ hg log -Ra -r0 -T '{(123)}\n'
2450 $ hg log -Ra -r0 -T '{(123)}\n'
2310 123
2451 123
2311 $ hg log -Ra -r0 -T '{(-4)}\n'
2452 $ hg log -Ra -r0 -T '{(-4)}\n'
2312 -4
2453 -4
2313 $ hg log -Ra -r0 -T '{(-)}\n'
2454 $ hg log -Ra -r0 -T '{(-)}\n'
2314 hg: parse error at 2: integer literal without digits
2455 hg: parse error at 2: integer literal without digits
2315 [255]
2456 [255]
2316 $ hg log -Ra -r0 -T '{(-a)}\n'
2457 $ hg log -Ra -r0 -T '{(-a)}\n'
2317 hg: parse error at 2: integer literal without digits
2458 hg: parse error at 2: integer literal without digits
2318 [255]
2459 [255]
2319
2460
2320 top-level integer literal is interpreted as symbol (i.e. variable name):
2461 top-level integer literal is interpreted as symbol (i.e. variable name):
2321
2462
2322 $ hg log -Ra -r0 -T '{1}\n'
2463 $ hg log -Ra -r0 -T '{1}\n'
2323
2464
2324 $ hg log -Ra -r0 -T '{if("t", "{1}")}\n'
2465 $ hg log -Ra -r0 -T '{if("t", "{1}")}\n'
2325
2466
2326 $ hg log -Ra -r0 -T '{1|stringify}\n'
2467 $ hg log -Ra -r0 -T '{1|stringify}\n'
2327
2468
2328
2469
2329 unless explicit symbol is expected:
2470 unless explicit symbol is expected:
2330
2471
2331 $ hg log -Ra -r0 -T '{desc|1}\n'
2472 $ hg log -Ra -r0 -T '{desc|1}\n'
2332 hg: parse error: expected a symbol, got 'integer'
2473 hg: parse error: expected a symbol, got 'integer'
2333 [255]
2474 [255]
2334 $ hg log -Ra -r0 -T '{1()}\n'
2475 $ hg log -Ra -r0 -T '{1()}\n'
2335 hg: parse error: expected a symbol, got 'integer'
2476 hg: parse error: expected a symbol, got 'integer'
2336 [255]
2477 [255]
2337
2478
2338 Test string escaping:
2479 Test string escaping:
2339
2480
2340 $ hg log -R latesttag -r 0 --template '>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2481 $ hg log -R latesttag -r 0 --template '>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2341 >
2482 >
2342 <>\n<[>
2483 <>\n<[>
2343 <>\n<]>
2484 <>\n<]>
2344 <>\n<
2485 <>\n<
2345
2486
2346 $ hg log -R latesttag -r 0 \
2487 $ hg log -R latesttag -r 0 \
2347 > --config ui.logtemplate='>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2488 > --config ui.logtemplate='>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2348 >
2489 >
2349 <>\n<[>
2490 <>\n<[>
2350 <>\n<]>
2491 <>\n<]>
2351 <>\n<
2492 <>\n<
2352
2493
2353 $ hg log -R latesttag -r 0 -T esc \
2494 $ hg log -R latesttag -r 0 -T esc \
2354 > --config templates.esc='>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2495 > --config templates.esc='>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2355 >
2496 >
2356 <>\n<[>
2497 <>\n<[>
2357 <>\n<]>
2498 <>\n<]>
2358 <>\n<
2499 <>\n<
2359
2500
2360 $ cat <<'EOF' > esctmpl
2501 $ cat <<'EOF' > esctmpl
2361 > changeset = '>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2502 > changeset = '>\n<>\\n<{if(rev, "[>\n<>\\n<]")}>\n<>\\n<\n'
2362 > EOF
2503 > EOF
2363 $ hg log -R latesttag -r 0 --style ./esctmpl
2504 $ hg log -R latesttag -r 0 --style ./esctmpl
2364 >
2505 >
2365 <>\n<[>
2506 <>\n<[>
2366 <>\n<]>
2507 <>\n<]>
2367 <>\n<
2508 <>\n<
2368
2509
2369 Test exception in quoted template. single backslash before quotation mark is
2510 Test exception in quoted template. single backslash before quotation mark is
2370 stripped before parsing:
2511 stripped before parsing:
2371
2512
2372 $ cat <<'EOF' > escquotetmpl
2513 $ cat <<'EOF' > escquotetmpl
2373 > changeset = "\" \\" \\\" \\\\" {files % \"{file}\"}\n"
2514 > changeset = "\" \\" \\\" \\\\" {files % \"{file}\"}\n"
2374 > EOF
2515 > EOF
2375 $ cd latesttag
2516 $ cd latesttag
2376 $ hg log -r 2 --style ../escquotetmpl
2517 $ hg log -r 2 --style ../escquotetmpl
2377 " \" \" \\" head1
2518 " \" \" \\" head1
2378
2519
2379 $ hg log -r 2 -T esc --config templates.esc='{\"invalid\"}\n'
2520 $ hg log -r 2 -T esc --config templates.esc='{\"invalid\"}\n'
2380 hg: parse error at 1: syntax error
2521 hg: parse error at 1: syntax error
2381 [255]
2522 [255]
2382 $ hg log -r 2 -T esc --config templates.esc='"{\"valid\"}\n"'
2523 $ hg log -r 2 -T esc --config templates.esc='"{\"valid\"}\n"'
2383 valid
2524 valid
2384 $ hg log -r 2 -T esc --config templates.esc="'"'{\'"'"'valid\'"'"'}\n'"'"
2525 $ hg log -r 2 -T esc --config templates.esc="'"'{\'"'"'valid\'"'"'}\n'"'"
2385 valid
2526 valid
2386 $ cd ..
2527 $ cd ..
2387
2528
2388 Test leading backslashes:
2529 Test leading backslashes:
2389
2530
2390 $ cd latesttag
2531 $ cd latesttag
2391 $ hg log -r 2 -T '\{rev} {files % "\{file}"} {files % r"\{file}"}\n'
2532 $ hg log -r 2 -T '\{rev} {files % "\{file}"} {files % r"\{file}"}\n'
2392 {rev} {file} \head1
2533 {rev} {file} \head1
2393 $ hg log -r 2 -T '\\{rev} {files % "\\{file}"} {files % r"\\{file}"}\n'
2534 $ hg log -r 2 -T '\\{rev} {files % "\\{file}"} {files % r"\\{file}"}\n'
2394 \2 \head1 \\head1
2535 \2 \head1 \\head1
2395 $ hg log -r 2 -T '\\\{rev} {files % "\\\{file}"} {files % r"\\\{file}"}\n'
2536 $ hg log -r 2 -T '\\\{rev} {files % "\\\{file}"} {files % r"\\\{file}"}\n'
2396 \{rev} \{file} \\\head1
2537 \{rev} \{file} \\\head1
2397 $ cd ..
2538 $ cd ..
2398
2539
2399 "string-escape"-ed "\x5c\x786e" becomes r"\x6e" (once) or r"n" (twice)
2540 "string-escape"-ed "\x5c\x786e" becomes r"\x6e" (once) or r"n" (twice)
2400
2541
2401 $ hg log -R a -r 0 --template '{if("1", "\x5c\x786e", "NG")}\n'
2542 $ hg log -R a -r 0 --template '{if("1", "\x5c\x786e", "NG")}\n'
2402 \x6e
2543 \x6e
2403 $ hg log -R a -r 0 --template '{if("1", r"\x5c\x786e", "NG")}\n'
2544 $ hg log -R a -r 0 --template '{if("1", r"\x5c\x786e", "NG")}\n'
2404 \x5c\x786e
2545 \x5c\x786e
2405 $ hg log -R a -r 0 --template '{if("", "NG", "\x5c\x786e")}\n'
2546 $ hg log -R a -r 0 --template '{if("", "NG", "\x5c\x786e")}\n'
2406 \x6e
2547 \x6e
2407 $ hg log -R a -r 0 --template '{if("", "NG", r"\x5c\x786e")}\n'
2548 $ hg log -R a -r 0 --template '{if("", "NG", r"\x5c\x786e")}\n'
2408 \x5c\x786e
2549 \x5c\x786e
2409
2550
2410 $ hg log -R a -r 2 --template '{ifeq("no perso\x6e", desc, "\x5c\x786e", "NG")}\n'
2551 $ hg log -R a -r 2 --template '{ifeq("no perso\x6e", desc, "\x5c\x786e", "NG")}\n'
2411 \x6e
2552 \x6e
2412 $ hg log -R a -r 2 --template '{ifeq(r"no perso\x6e", desc, "NG", r"\x5c\x786e")}\n'
2553 $ hg log -R a -r 2 --template '{ifeq(r"no perso\x6e", desc, "NG", r"\x5c\x786e")}\n'
2413 \x5c\x786e
2554 \x5c\x786e
2414 $ hg log -R a -r 2 --template '{ifeq(desc, "no perso\x6e", "\x5c\x786e", "NG")}\n'
2555 $ hg log -R a -r 2 --template '{ifeq(desc, "no perso\x6e", "\x5c\x786e", "NG")}\n'
2415 \x6e
2556 \x6e
2416 $ hg log -R a -r 2 --template '{ifeq(desc, r"no perso\x6e", "NG", r"\x5c\x786e")}\n'
2557 $ hg log -R a -r 2 --template '{ifeq(desc, r"no perso\x6e", "NG", r"\x5c\x786e")}\n'
2417 \x5c\x786e
2558 \x5c\x786e
2418
2559
2419 $ hg log -R a -r 8 --template '{join(files, "\n")}\n'
2560 $ hg log -R a -r 8 --template '{join(files, "\n")}\n'
2420 fourth
2561 fourth
2421 second
2562 second
2422 third
2563 third
2423 $ hg log -R a -r 8 --template '{join(files, r"\n")}\n'
2564 $ hg log -R a -r 8 --template '{join(files, r"\n")}\n'
2424 fourth\nsecond\nthird
2565 fourth\nsecond\nthird
2425
2566
2426 $ hg log -R a -r 2 --template '{rstdoc("1st\n\n2nd", "htm\x6c")}'
2567 $ hg log -R a -r 2 --template '{rstdoc("1st\n\n2nd", "htm\x6c")}'
2427 <p>
2568 <p>
2428 1st
2569 1st
2429 </p>
2570 </p>
2430 <p>
2571 <p>
2431 2nd
2572 2nd
2432 </p>
2573 </p>
2433 $ hg log -R a -r 2 --template '{rstdoc(r"1st\n\n2nd", "html")}'
2574 $ hg log -R a -r 2 --template '{rstdoc(r"1st\n\n2nd", "html")}'
2434 <p>
2575 <p>
2435 1st\n\n2nd
2576 1st\n\n2nd
2436 </p>
2577 </p>
2437 $ hg log -R a -r 2 --template '{rstdoc("1st\n\n2nd", r"htm\x6c")}'
2578 $ hg log -R a -r 2 --template '{rstdoc("1st\n\n2nd", r"htm\x6c")}'
2438 1st
2579 1st
2439
2580
2440 2nd
2581 2nd
2441
2582
2442 $ hg log -R a -r 2 --template '{strip(desc, "\x6e")}\n'
2583 $ hg log -R a -r 2 --template '{strip(desc, "\x6e")}\n'
2443 o perso
2584 o perso
2444 $ hg log -R a -r 2 --template '{strip(desc, r"\x6e")}\n'
2585 $ hg log -R a -r 2 --template '{strip(desc, r"\x6e")}\n'
2445 no person
2586 no person
2446 $ hg log -R a -r 2 --template '{strip("no perso\x6e", "\x6e")}\n'
2587 $ hg log -R a -r 2 --template '{strip("no perso\x6e", "\x6e")}\n'
2447 o perso
2588 o perso
2448 $ hg log -R a -r 2 --template '{strip(r"no perso\x6e", r"\x6e")}\n'
2589 $ hg log -R a -r 2 --template '{strip(r"no perso\x6e", r"\x6e")}\n'
2449 no perso
2590 no perso
2450
2591
2451 $ hg log -R a -r 2 --template '{sub("\\x6e", "\x2d", desc)}\n'
2592 $ hg log -R a -r 2 --template '{sub("\\x6e", "\x2d", desc)}\n'
2452 -o perso-
2593 -o perso-
2453 $ hg log -R a -r 2 --template '{sub(r"\\x6e", "-", desc)}\n'
2594 $ hg log -R a -r 2 --template '{sub(r"\\x6e", "-", desc)}\n'
2454 no person
2595 no person
2455 $ hg log -R a -r 2 --template '{sub("n", r"\x2d", desc)}\n'
2596 $ hg log -R a -r 2 --template '{sub("n", r"\x2d", desc)}\n'
2456 \x2do perso\x2d
2597 \x2do perso\x2d
2457 $ hg log -R a -r 2 --template '{sub("n", "\x2d", "no perso\x6e")}\n'
2598 $ hg log -R a -r 2 --template '{sub("n", "\x2d", "no perso\x6e")}\n'
2458 -o perso-
2599 -o perso-
2459 $ hg log -R a -r 2 --template '{sub("n", r"\x2d", r"no perso\x6e")}\n'
2600 $ hg log -R a -r 2 --template '{sub("n", r"\x2d", r"no perso\x6e")}\n'
2460 \x2do perso\x6e
2601 \x2do perso\x6e
2461
2602
2462 $ hg log -R a -r 8 --template '{files % "{file}\n"}'
2603 $ hg log -R a -r 8 --template '{files % "{file}\n"}'
2463 fourth
2604 fourth
2464 second
2605 second
2465 third
2606 third
2466 $ hg log -R a -r 8 --template '{files % r"{file}\n"}\n'
2607 $ hg log -R a -r 8 --template '{files % r"{file}\n"}\n'
2467 fourth\nsecond\nthird\n
2608 fourth\nsecond\nthird\n
2468
2609
2469 Test string escaping in nested expression:
2610 Test string escaping in nested expression:
2470
2611
2471 $ hg log -R a -r 8 --template '{ifeq(r"\x6e", if("1", "\x5c\x786e"), join(files, "\x5c\x786e"))}\n'
2612 $ hg log -R a -r 8 --template '{ifeq(r"\x6e", if("1", "\x5c\x786e"), join(files, "\x5c\x786e"))}\n'
2472 fourth\x6esecond\x6ethird
2613 fourth\x6esecond\x6ethird
2473 $ hg log -R a -r 8 --template '{ifeq(if("1", r"\x6e"), "\x5c\x786e", join(files, "\x5c\x786e"))}\n'
2614 $ hg log -R a -r 8 --template '{ifeq(if("1", r"\x6e"), "\x5c\x786e", join(files, "\x5c\x786e"))}\n'
2474 fourth\x6esecond\x6ethird
2615 fourth\x6esecond\x6ethird
2475
2616
2476 $ hg log -R a -r 8 --template '{join(files, ifeq(branch, "default", "\x5c\x786e"))}\n'
2617 $ hg log -R a -r 8 --template '{join(files, ifeq(branch, "default", "\x5c\x786e"))}\n'
2477 fourth\x6esecond\x6ethird
2618 fourth\x6esecond\x6ethird
2478 $ hg log -R a -r 8 --template '{join(files, ifeq(branch, "default", r"\x5c\x786e"))}\n'
2619 $ hg log -R a -r 8 --template '{join(files, ifeq(branch, "default", r"\x5c\x786e"))}\n'
2479 fourth\x5c\x786esecond\x5c\x786ethird
2620 fourth\x5c\x786esecond\x5c\x786ethird
2480
2621
2481 $ hg log -R a -r 3:4 --template '{rev}:{sub(if("1", "\x6e"), ifeq(branch, "foo", r"\x5c\x786e", "\x5c\x786e"), desc)}\n'
2622 $ hg log -R a -r 3:4 --template '{rev}:{sub(if("1", "\x6e"), ifeq(branch, "foo", r"\x5c\x786e", "\x5c\x786e"), desc)}\n'
2482 3:\x6eo user, \x6eo domai\x6e
2623 3:\x6eo user, \x6eo domai\x6e
2483 4:\x5c\x786eew bra\x5c\x786ech
2624 4:\x5c\x786eew bra\x5c\x786ech
2484
2625
2485 Test recursive evaluation:
2626 Test recursive evaluation:
2486
2627
2487 $ hg init r
2628 $ hg init r
2488 $ cd r
2629 $ cd r
2489 $ echo a > a
2630 $ echo a > a
2490 $ hg ci -Am '{rev}'
2631 $ hg ci -Am '{rev}'
2491 adding a
2632 adding a
2492 $ hg log -r 0 --template '{if(rev, desc)}\n'
2633 $ hg log -r 0 --template '{if(rev, desc)}\n'
2493 {rev}
2634 {rev}
2494 $ hg log -r 0 --template '{if(rev, "{author} {rev}")}\n'
2635 $ hg log -r 0 --template '{if(rev, "{author} {rev}")}\n'
2495 test 0
2636 test 0
2496
2637
2497 $ hg branch -q 'text.{rev}'
2638 $ hg branch -q 'text.{rev}'
2498 $ echo aa >> aa
2639 $ echo aa >> aa
2499 $ hg ci -u '{node|short}' -m 'desc to be wrapped desc to be wrapped'
2640 $ hg ci -u '{node|short}' -m 'desc to be wrapped desc to be wrapped'
2500
2641
2501 $ hg log -l1 --template '{fill(desc, "20", author, branch)}'
2642 $ hg log -l1 --template '{fill(desc, "20", author, branch)}'
2502 {node|short}desc to
2643 {node|short}desc to
2503 text.{rev}be wrapped
2644 text.{rev}be wrapped
2504 text.{rev}desc to be
2645 text.{rev}desc to be
2505 text.{rev}wrapped (no-eol)
2646 text.{rev}wrapped (no-eol)
2506 $ hg log -l1 --template '{fill(desc, "20", "{node|short}:", "text.{rev}:")}'
2647 $ hg log -l1 --template '{fill(desc, "20", "{node|short}:", "text.{rev}:")}'
2507 bcc7ff960b8e:desc to
2648 bcc7ff960b8e:desc to
2508 text.1:be wrapped
2649 text.1:be wrapped
2509 text.1:desc to be
2650 text.1:desc to be
2510 text.1:wrapped (no-eol)
2651 text.1:wrapped (no-eol)
2511
2652
2512 $ hg log -l 1 --template '{sub(r"[0-9]", "-", author)}'
2653 $ hg log -l 1 --template '{sub(r"[0-9]", "-", author)}'
2513 {node|short} (no-eol)
2654 {node|short} (no-eol)
2514 $ hg log -l 1 --template '{sub(r"[0-9]", "-", "{node|short}")}'
2655 $ hg log -l 1 --template '{sub(r"[0-9]", "-", "{node|short}")}'
2515 bcc-ff---b-e (no-eol)
2656 bcc-ff---b-e (no-eol)
2516
2657
2517 $ cat >> .hg/hgrc <<EOF
2658 $ cat >> .hg/hgrc <<EOF
2518 > [extensions]
2659 > [extensions]
2519 > color=
2660 > color=
2520 > [color]
2661 > [color]
2521 > mode=ansi
2662 > mode=ansi
2522 > text.{rev} = red
2663 > text.{rev} = red
2523 > text.1 = green
2664 > text.1 = green
2524 > EOF
2665 > EOF
2525 $ hg log --color=always -l 1 --template '{label(branch, "text\n")}'
2666 $ hg log --color=always -l 1 --template '{label(branch, "text\n")}'
2526 \x1b[0;31mtext\x1b[0m (esc)
2667 \x1b[0;31mtext\x1b[0m (esc)
2527 $ hg log --color=always -l 1 --template '{label("text.{rev}", "text\n")}'
2668 $ hg log --color=always -l 1 --template '{label("text.{rev}", "text\n")}'
2528 \x1b[0;32mtext\x1b[0m (esc)
2669 \x1b[0;32mtext\x1b[0m (esc)
2529
2670
2530 Test branches inside if statement:
2671 Test branches inside if statement:
2531
2672
2532 $ hg log -r 0 --template '{if(branches, "yes", "no")}\n'
2673 $ hg log -r 0 --template '{if(branches, "yes", "no")}\n'
2533 no
2674 no
2534
2675
2535 Test get function:
2676 Test get function:
2536
2677
2537 $ hg log -r 0 --template '{get(extras, "branch")}\n'
2678 $ hg log -r 0 --template '{get(extras, "branch")}\n'
2538 default
2679 default
2539 $ hg log -r 0 --template '{get(files, "should_fail")}\n'
2680 $ hg log -r 0 --template '{get(files, "should_fail")}\n'
2540 hg: parse error: get() expects a dict as first argument
2681 hg: parse error: get() expects a dict as first argument
2541 [255]
2682 [255]
2542
2683
2543 Test shortest(node) function:
2684 Test shortest(node) function:
2544
2685
2545 $ echo b > b
2686 $ echo b > b
2546 $ hg ci -qAm b
2687 $ hg ci -qAm b
2547 $ hg log --template '{shortest(node)}\n'
2688 $ hg log --template '{shortest(node)}\n'
2548 e777
2689 e777
2549 bcc7
2690 bcc7
2550 f776
2691 f776
2551 $ hg log --template '{shortest(node, 10)}\n'
2692 $ hg log --template '{shortest(node, 10)}\n'
2552 e777603221
2693 e777603221
2553 bcc7ff960b
2694 bcc7ff960b
2554 f7769ec2ab
2695 f7769ec2ab
2555
2696
2556 Test pad function
2697 Test pad function
2557
2698
2558 $ hg log --template '{pad(rev, 20)} {author|user}\n'
2699 $ hg log --template '{pad(rev, 20)} {author|user}\n'
2559 2 test
2700 2 test
2560 1 {node|short}
2701 1 {node|short}
2561 0 test
2702 0 test
2562
2703
2563 $ hg log --template '{pad(rev, 20, " ", True)} {author|user}\n'
2704 $ hg log --template '{pad(rev, 20, " ", True)} {author|user}\n'
2564 2 test
2705 2 test
2565 1 {node|short}
2706 1 {node|short}
2566 0 test
2707 0 test
2567
2708
2568 $ hg log --template '{pad(rev, 20, "-", False)} {author|user}\n'
2709 $ hg log --template '{pad(rev, 20, "-", False)} {author|user}\n'
2569 2------------------- test
2710 2------------------- test
2570 1------------------- {node|short}
2711 1------------------- {node|short}
2571 0------------------- test
2712 0------------------- test
2572
2713
2573 Test ifcontains function
2714 Test ifcontains function
2574
2715
2575 $ hg log --template '{rev} {ifcontains(rev, "2 two 0", "is in the string", "is not")}\n'
2716 $ hg log --template '{rev} {ifcontains(rev, "2 two 0", "is in the string", "is not")}\n'
2576 2 is in the string
2717 2 is in the string
2577 1 is not
2718 1 is not
2578 0 is in the string
2719 0 is in the string
2579
2720
2580 $ hg log --template '{rev} {ifcontains("a", file_adds, "added a", "did not add a")}\n'
2721 $ hg log --template '{rev} {ifcontains("a", file_adds, "added a", "did not add a")}\n'
2581 2 did not add a
2722 2 did not add a
2582 1 did not add a
2723 1 did not add a
2583 0 added a
2724 0 added a
2584
2725
2585 Test revset function
2726 Test revset function
2586
2727
2587 $ hg log --template '{rev} {ifcontains(rev, revset("."), "current rev", "not current rev")}\n'
2728 $ hg log --template '{rev} {ifcontains(rev, revset("."), "current rev", "not current rev")}\n'
2588 2 current rev
2729 2 current rev
2589 1 not current rev
2730 1 not current rev
2590 0 not current rev
2731 0 not current rev
2591
2732
2592 $ hg log --template '{rev} {ifcontains(rev, revset(". + .^"), "match rev", "not match rev")}\n'
2733 $ hg log --template '{rev} {ifcontains(rev, revset(". + .^"), "match rev", "not match rev")}\n'
2593 2 match rev
2734 2 match rev
2594 1 match rev
2735 1 match rev
2595 0 not match rev
2736 0 not match rev
2596
2737
2597 $ hg log --template '{rev} Parents: {revset("parents(%s)", rev)}\n'
2738 $ hg log --template '{rev} Parents: {revset("parents(%s)", rev)}\n'
2598 2 Parents: 1
2739 2 Parents: 1
2599 1 Parents: 0
2740 1 Parents: 0
2600 0 Parents:
2741 0 Parents:
2601
2742
2602 $ cat >> .hg/hgrc <<EOF
2743 $ cat >> .hg/hgrc <<EOF
2603 > [revsetalias]
2744 > [revsetalias]
2604 > myparents(\$1) = parents(\$1)
2745 > myparents(\$1) = parents(\$1)
2605 > EOF
2746 > EOF
2606 $ hg log --template '{rev} Parents: {revset("myparents(%s)", rev)}\n'
2747 $ hg log --template '{rev} Parents: {revset("myparents(%s)", rev)}\n'
2607 2 Parents: 1
2748 2 Parents: 1
2608 1 Parents: 0
2749 1 Parents: 0
2609 0 Parents:
2750 0 Parents:
2610
2751
2611 $ hg log --template 'Rev: {rev}\n{revset("::%s", rev) % "Ancestor: {revision}\n"}\n'
2752 $ hg log --template 'Rev: {rev}\n{revset("::%s", rev) % "Ancestor: {revision}\n"}\n'
2612 Rev: 2
2753 Rev: 2
2613 Ancestor: 0
2754 Ancestor: 0
2614 Ancestor: 1
2755 Ancestor: 1
2615 Ancestor: 2
2756 Ancestor: 2
2616
2757
2617 Rev: 1
2758 Rev: 1
2618 Ancestor: 0
2759 Ancestor: 0
2619 Ancestor: 1
2760 Ancestor: 1
2620
2761
2621 Rev: 0
2762 Rev: 0
2622 Ancestor: 0
2763 Ancestor: 0
2623
2764
2624 Test current bookmark templating
2765 Test current bookmark templating
2625
2766
2626 $ hg book foo
2767 $ hg book foo
2627 $ hg book bar
2768 $ hg book bar
2628 $ hg log --template "{rev} {bookmarks % '{bookmark}{ifeq(bookmark, current, \"*\")} '}\n"
2769 $ hg log --template "{rev} {bookmarks % '{bookmark}{ifeq(bookmark, current, \"*\")} '}\n"
2629 2 bar* foo
2770 2 bar* foo
2630 1
2771 1
2631 0
2772 0
2632 $ hg log --template "{rev} {currentbookmark}\n"
2773 $ hg log --template "{rev} {currentbookmark}\n"
2633 2 bar
2774 2 bar
2634 1
2775 1
2635 0
2776 0
2636 $ hg bookmarks --inactive bar
2777 $ hg bookmarks --inactive bar
2637 $ hg log --template "{rev} {currentbookmark}\n"
2778 $ hg log --template "{rev} {currentbookmark}\n"
2638 2
2779 2
2639 1
2780 1
2640 0
2781 0
2641 $ hg book -r1 baz
2782 $ hg book -r1 baz
2642 $ hg log --template "{rev} {join(bookmarks, ' ')}\n"
2783 $ hg log --template "{rev} {join(bookmarks, ' ')}\n"
2643 2 bar foo
2784 2 bar foo
2644 1 baz
2785 1 baz
2645 0
2786 0
2646 $ hg log --template "{rev} {ifcontains('foo', bookmarks, 't', 'f')}\n"
2787 $ hg log --template "{rev} {ifcontains('foo', bookmarks, 't', 'f')}\n"
2647 2 t
2788 2 t
2648 1 f
2789 1 f
2649 0 f
2790 0 f
2650
2791
2651 Test stringify on sub expressions
2792 Test stringify on sub expressions
2652
2793
2653 $ cd ..
2794 $ cd ..
2654 $ hg log -R a -r 8 --template '{join(files, if("1", if("1", ", ")))}\n'
2795 $ hg log -R a -r 8 --template '{join(files, if("1", if("1", ", ")))}\n'
2655 fourth, second, third
2796 fourth, second, third
2656 $ hg log -R a -r 8 --template '{strip(if("1", if("1", "-abc-")), if("1", if("1", "-")))}\n'
2797 $ hg log -R a -r 8 --template '{strip(if("1", if("1", "-abc-")), if("1", if("1", "-")))}\n'
2657 abc
2798 abc
2658
2799
2659 Test splitlines
2800 Test splitlines
2660
2801
2661 $ hg log -Gv -R a --template "{splitlines(desc) % 'foo {line}\n'}"
2802 $ hg log -Gv -R a --template "{splitlines(desc) % 'foo {line}\n'}"
2662 @ foo Modify, add, remove, rename
2803 @ foo Modify, add, remove, rename
2663 |
2804 |
2664 o foo future
2805 o foo future
2665 |
2806 |
2666 o foo third
2807 o foo third
2667 |
2808 |
2668 o foo second
2809 o foo second
2669
2810
2670 o foo merge
2811 o foo merge
2671 |\
2812 |\
2672 | o foo new head
2813 | o foo new head
2673 | |
2814 | |
2674 o | foo new branch
2815 o | foo new branch
2675 |/
2816 |/
2676 o foo no user, no domain
2817 o foo no user, no domain
2677 |
2818 |
2678 o foo no person
2819 o foo no person
2679 |
2820 |
2680 o foo other 1
2821 o foo other 1
2681 | foo other 2
2822 | foo other 2
2682 | foo
2823 | foo
2683 | foo other 3
2824 | foo other 3
2684 o foo line 1
2825 o foo line 1
2685 foo line 2
2826 foo line 2
2686
2827
2687 Test startswith
2828 Test startswith
2688 $ hg log -Gv -R a --template "{startswith(desc)}"
2829 $ hg log -Gv -R a --template "{startswith(desc)}"
2689 hg: parse error: startswith expects two arguments
2830 hg: parse error: startswith expects two arguments
2690 [255]
2831 [255]
2691
2832
2692 $ hg log -Gv -R a --template "{startswith('line', desc)}"
2833 $ hg log -Gv -R a --template "{startswith('line', desc)}"
2693 @
2834 @
2694 |
2835 |
2695 o
2836 o
2696 |
2837 |
2697 o
2838 o
2698 |
2839 |
2699 o
2840 o
2700
2841
2701 o
2842 o
2702 |\
2843 |\
2703 | o
2844 | o
2704 | |
2845 | |
2705 o |
2846 o |
2706 |/
2847 |/
2707 o
2848 o
2708 |
2849 |
2709 o
2850 o
2710 |
2851 |
2711 o
2852 o
2712 |
2853 |
2713 o line 1
2854 o line 1
2714 line 2
2855 line 2
2715
2856
2716 Test bad template with better error message
2857 Test bad template with better error message
2717
2858
2718 $ hg log -Gv -R a --template '{desc|user()}'
2859 $ hg log -Gv -R a --template '{desc|user()}'
2719 hg: parse error: expected a symbol, got 'func'
2860 hg: parse error: expected a symbol, got 'func'
2720 [255]
2861 [255]
2721
2862
2722 Test word function (including index out of bounds graceful failure)
2863 Test word function (including index out of bounds graceful failure)
2723
2864
2724 $ hg log -Gv -R a --template "{word('1', desc)}"
2865 $ hg log -Gv -R a --template "{word('1', desc)}"
2725 @ add,
2866 @ add,
2726 |
2867 |
2727 o
2868 o
2728 |
2869 |
2729 o
2870 o
2730 |
2871 |
2731 o
2872 o
2732
2873
2733 o
2874 o
2734 |\
2875 |\
2735 | o head
2876 | o head
2736 | |
2877 | |
2737 o | branch
2878 o | branch
2738 |/
2879 |/
2739 o user,
2880 o user,
2740 |
2881 |
2741 o person
2882 o person
2742 |
2883 |
2743 o 1
2884 o 1
2744 |
2885 |
2745 o 1
2886 o 1
2746
2887
2747
2888
2748 Test word third parameter used as splitter
2889 Test word third parameter used as splitter
2749
2890
2750 $ hg log -Gv -R a --template "{word('0', desc, 'o')}"
2891 $ hg log -Gv -R a --template "{word('0', desc, 'o')}"
2751 @ M
2892 @ M
2752 |
2893 |
2753 o future
2894 o future
2754 |
2895 |
2755 o third
2896 o third
2756 |
2897 |
2757 o sec
2898 o sec
2758
2899
2759 o merge
2900 o merge
2760 |\
2901 |\
2761 | o new head
2902 | o new head
2762 | |
2903 | |
2763 o | new branch
2904 o | new branch
2764 |/
2905 |/
2765 o n
2906 o n
2766 |
2907 |
2767 o n
2908 o n
2768 |
2909 |
2769 o
2910 o
2770 |
2911 |
2771 o line 1
2912 o line 1
2772 line 2
2913 line 2
2773
2914
2774 Test word error messages for not enough and too many arguments
2915 Test word error messages for not enough and too many arguments
2775
2916
2776 $ hg log -Gv -R a --template "{word('0')}"
2917 $ hg log -Gv -R a --template "{word('0')}"
2777 hg: parse error: word expects two or three arguments, got 1
2918 hg: parse error: word expects two or three arguments, got 1
2778 [255]
2919 [255]
2779
2920
2780 $ hg log -Gv -R a --template "{word('0', desc, 'o', 'h', 'b', 'o', 'y')}"
2921 $ hg log -Gv -R a --template "{word('0', desc, 'o', 'h', 'b', 'o', 'y')}"
2781 hg: parse error: word expects two or three arguments, got 7
2922 hg: parse error: word expects two or three arguments, got 7
2782 [255]
2923 [255]
2783
2924
2784 Test word for integer literal
2925 Test word for integer literal
2785
2926
2786 $ hg log -R a --template "{word(2, desc)}\n" -r0
2927 $ hg log -R a --template "{word(2, desc)}\n" -r0
2787 line
2928 line
2788
2929
2789 Test word for invalid numbers
2930 Test word for invalid numbers
2790
2931
2791 $ hg log -Gv -R a --template "{word('a', desc)}"
2932 $ hg log -Gv -R a --template "{word('a', desc)}"
2792 hg: parse error: word expects an integer index
2933 hg: parse error: word expects an integer index
2793 [255]
2934 [255]
@@ -1,2052 +1,2052 b''
1 Log on empty repository: checking consistency
1 Log on empty repository: checking consistency
2
2
3 $ hg init empty
3 $ hg init empty
4 $ cd empty
4 $ cd empty
5 $ hg log
5 $ hg log
6 $ hg log -r 1
6 $ hg log -r 1
7 abort: unknown revision '1'!
7 abort: unknown revision '1'!
8 [255]
8 [255]
9 $ hg log -r -1:0
9 $ hg log -r -1:0
10 abort: unknown revision '-1'!
10 abort: unknown revision '-1'!
11 [255]
11 [255]
12 $ hg log -r 'branch(name)'
12 $ hg log -r 'branch(name)'
13 abort: unknown revision 'name'!
13 abort: unknown revision 'name'!
14 [255]
14 [255]
15 $ hg log -r null -q
15 $ hg log -r null -q
16 -1:000000000000
16 -1:000000000000
17
17
18 The g is crafted to have 2 filelog topological heads in a linear
18 The g is crafted to have 2 filelog topological heads in a linear
19 changeset graph
19 changeset graph
20
20
21 $ hg init a
21 $ hg init a
22 $ cd a
22 $ cd a
23 $ echo a > a
23 $ echo a > a
24 $ echo f > f
24 $ echo f > f
25 $ hg ci -Ama -d '1 0'
25 $ hg ci -Ama -d '1 0'
26 adding a
26 adding a
27 adding f
27 adding f
28
28
29 $ hg cp a b
29 $ hg cp a b
30 $ hg cp f g
30 $ hg cp f g
31 $ hg ci -mb -d '2 0'
31 $ hg ci -mb -d '2 0'
32
32
33 $ mkdir dir
33 $ mkdir dir
34 $ hg mv b dir
34 $ hg mv b dir
35 $ echo g >> g
35 $ echo g >> g
36 $ echo f >> f
36 $ echo f >> f
37 $ hg ci -mc -d '3 0'
37 $ hg ci -mc -d '3 0'
38
38
39 $ hg mv a b
39 $ hg mv a b
40 $ hg cp -f f g
40 $ hg cp -f f g
41 $ echo a > d
41 $ echo a > d
42 $ hg add d
42 $ hg add d
43 $ hg ci -md -d '4 0'
43 $ hg ci -md -d '4 0'
44
44
45 $ hg mv dir/b e
45 $ hg mv dir/b e
46 $ hg ci -me -d '5 0'
46 $ hg ci -me -d '5 0'
47
47
48 Make sure largefiles doesn't interfere with logging a regular file
48 Make sure largefiles doesn't interfere with logging a regular file
49 $ hg --debug log a -T '{rev}: {desc}\n' --config extensions.largefiles=
49 $ hg --debug log a -T '{rev}: {desc}\n' --config extensions.largefiles=
50 updated patterns: ['.hglf/a', 'a']
50 updated patterns: ['.hglf/a', 'a']
51 0: a
51 0: a
52 $ hg log a
52 $ hg log a
53 changeset: 0:9161b9aeaf16
53 changeset: 0:9161b9aeaf16
54 user: test
54 user: test
55 date: Thu Jan 01 00:00:01 1970 +0000
55 date: Thu Jan 01 00:00:01 1970 +0000
56 summary: a
56 summary: a
57
57
58 $ hg log glob:a*
58 $ hg log glob:a*
59 changeset: 3:2ca5ba701980
59 changeset: 3:2ca5ba701980
60 user: test
60 user: test
61 date: Thu Jan 01 00:00:04 1970 +0000
61 date: Thu Jan 01 00:00:04 1970 +0000
62 summary: d
62 summary: d
63
63
64 changeset: 0:9161b9aeaf16
64 changeset: 0:9161b9aeaf16
65 user: test
65 user: test
66 date: Thu Jan 01 00:00:01 1970 +0000
66 date: Thu Jan 01 00:00:01 1970 +0000
67 summary: a
67 summary: a
68
68
69 $ hg --debug log glob:a* -T '{rev}: {desc}\n' --config extensions.largefiles=
69 $ hg --debug log glob:a* -T '{rev}: {desc}\n' --config extensions.largefiles=
70 updated patterns: ['glob:.hglf/a*', 'glob:a*']
70 updated patterns: ['glob:.hglf/a*', 'glob:a*']
71 3: d
71 3: d
72 0: a
72 0: a
73
73
74 log on directory
74 log on directory
75
75
76 $ hg log dir
76 $ hg log dir
77 changeset: 4:7e4639b4691b
77 changeset: 4:7e4639b4691b
78 tag: tip
78 tag: tip
79 user: test
79 user: test
80 date: Thu Jan 01 00:00:05 1970 +0000
80 date: Thu Jan 01 00:00:05 1970 +0000
81 summary: e
81 summary: e
82
82
83 changeset: 2:f8954cd4dc1f
83 changeset: 2:f8954cd4dc1f
84 user: test
84 user: test
85 date: Thu Jan 01 00:00:03 1970 +0000
85 date: Thu Jan 01 00:00:03 1970 +0000
86 summary: c
86 summary: c
87
87
88 $ hg log somethingthatdoesntexist dir
88 $ hg log somethingthatdoesntexist dir
89 changeset: 4:7e4639b4691b
89 changeset: 4:7e4639b4691b
90 tag: tip
90 tag: tip
91 user: test
91 user: test
92 date: Thu Jan 01 00:00:05 1970 +0000
92 date: Thu Jan 01 00:00:05 1970 +0000
93 summary: e
93 summary: e
94
94
95 changeset: 2:f8954cd4dc1f
95 changeset: 2:f8954cd4dc1f
96 user: test
96 user: test
97 date: Thu Jan 01 00:00:03 1970 +0000
97 date: Thu Jan 01 00:00:03 1970 +0000
98 summary: c
98 summary: c
99
99
100
100
101 -f, non-existent directory
101 -f, non-existent directory
102
102
103 $ hg log -f dir
103 $ hg log -f dir
104 abort: cannot follow file not in parent revision: "dir"
104 abort: cannot follow file not in parent revision: "dir"
105 [255]
105 [255]
106
106
107 -f, directory
107 -f, directory
108
108
109 $ hg up -q 3
109 $ hg up -q 3
110 $ hg log -f dir
110 $ hg log -f dir
111 changeset: 2:f8954cd4dc1f
111 changeset: 2:f8954cd4dc1f
112 user: test
112 user: test
113 date: Thu Jan 01 00:00:03 1970 +0000
113 date: Thu Jan 01 00:00:03 1970 +0000
114 summary: c
114 summary: c
115
115
116 -f, directory with --patch
116 -f, directory with --patch
117
117
118 $ hg log -f dir -p
118 $ hg log -f dir -p
119 changeset: 2:f8954cd4dc1f
119 changeset: 2:f8954cd4dc1f
120 user: test
120 user: test
121 date: Thu Jan 01 00:00:03 1970 +0000
121 date: Thu Jan 01 00:00:03 1970 +0000
122 summary: c
122 summary: c
123
123
124 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
124 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
125 --- /dev/null* (glob)
125 --- /dev/null* (glob)
126 +++ b/dir/b* (glob)
126 +++ b/dir/b* (glob)
127 @@ -0,0 +1,1 @@
127 @@ -0,0 +1,1 @@
128 +a
128 +a
129
129
130
130
131 -f, pattern
131 -f, pattern
132
132
133 $ hg log -f -I 'dir**' -p
133 $ hg log -f -I 'dir**' -p
134 changeset: 2:f8954cd4dc1f
134 changeset: 2:f8954cd4dc1f
135 user: test
135 user: test
136 date: Thu Jan 01 00:00:03 1970 +0000
136 date: Thu Jan 01 00:00:03 1970 +0000
137 summary: c
137 summary: c
138
138
139 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
139 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
140 --- /dev/null* (glob)
140 --- /dev/null* (glob)
141 +++ b/dir/b* (glob)
141 +++ b/dir/b* (glob)
142 @@ -0,0 +1,1 @@
142 @@ -0,0 +1,1 @@
143 +a
143 +a
144
144
145 $ hg up -q 4
145 $ hg up -q 4
146
146
147 -f, a wrong style
147 -f, a wrong style
148
148
149 $ hg log -f -l1 --style something
149 $ hg log -f -l1 --style something
150 abort: style 'something' not found
150 abort: style 'something' not found
151 (available styles: bisect, changelog, compact, default, phases, xml)
151 (available styles: bisect, changelog, compact, default, phases, status, xml)
152 [255]
152 [255]
153
153
154 -f, phases style
154 -f, phases style
155
155
156
156
157 $ hg log -f -l1 --style phases
157 $ hg log -f -l1 --style phases
158 changeset: 4:7e4639b4691b
158 changeset: 4:7e4639b4691b
159 tag: tip
159 tag: tip
160 phase: draft
160 phase: draft
161 user: test
161 user: test
162 date: Thu Jan 01 00:00:05 1970 +0000
162 date: Thu Jan 01 00:00:05 1970 +0000
163 summary: e
163 summary: e
164
164
165
165
166 $ hg log -f -l1 --style phases -q
166 $ hg log -f -l1 --style phases -q
167 4:7e4639b4691b
167 4:7e4639b4691b
168
168
169 -f, but no args
169 -f, but no args
170
170
171 $ hg log -f
171 $ hg log -f
172 changeset: 4:7e4639b4691b
172 changeset: 4:7e4639b4691b
173 tag: tip
173 tag: tip
174 user: test
174 user: test
175 date: Thu Jan 01 00:00:05 1970 +0000
175 date: Thu Jan 01 00:00:05 1970 +0000
176 summary: e
176 summary: e
177
177
178 changeset: 3:2ca5ba701980
178 changeset: 3:2ca5ba701980
179 user: test
179 user: test
180 date: Thu Jan 01 00:00:04 1970 +0000
180 date: Thu Jan 01 00:00:04 1970 +0000
181 summary: d
181 summary: d
182
182
183 changeset: 2:f8954cd4dc1f
183 changeset: 2:f8954cd4dc1f
184 user: test
184 user: test
185 date: Thu Jan 01 00:00:03 1970 +0000
185 date: Thu Jan 01 00:00:03 1970 +0000
186 summary: c
186 summary: c
187
187
188 changeset: 1:d89b0a12d229
188 changeset: 1:d89b0a12d229
189 user: test
189 user: test
190 date: Thu Jan 01 00:00:02 1970 +0000
190 date: Thu Jan 01 00:00:02 1970 +0000
191 summary: b
191 summary: b
192
192
193 changeset: 0:9161b9aeaf16
193 changeset: 0:9161b9aeaf16
194 user: test
194 user: test
195 date: Thu Jan 01 00:00:01 1970 +0000
195 date: Thu Jan 01 00:00:01 1970 +0000
196 summary: a
196 summary: a
197
197
198
198
199 one rename
199 one rename
200
200
201 $ hg up -q 2
201 $ hg up -q 2
202 $ hg log -vf a
202 $ hg log -vf a
203 changeset: 0:9161b9aeaf16
203 changeset: 0:9161b9aeaf16
204 user: test
204 user: test
205 date: Thu Jan 01 00:00:01 1970 +0000
205 date: Thu Jan 01 00:00:01 1970 +0000
206 files: a f
206 files: a f
207 description:
207 description:
208 a
208 a
209
209
210
210
211
211
212 many renames
212 many renames
213
213
214 $ hg up -q tip
214 $ hg up -q tip
215 $ hg log -vf e
215 $ hg log -vf e
216 changeset: 4:7e4639b4691b
216 changeset: 4:7e4639b4691b
217 tag: tip
217 tag: tip
218 user: test
218 user: test
219 date: Thu Jan 01 00:00:05 1970 +0000
219 date: Thu Jan 01 00:00:05 1970 +0000
220 files: dir/b e
220 files: dir/b e
221 description:
221 description:
222 e
222 e
223
223
224
224
225 changeset: 2:f8954cd4dc1f
225 changeset: 2:f8954cd4dc1f
226 user: test
226 user: test
227 date: Thu Jan 01 00:00:03 1970 +0000
227 date: Thu Jan 01 00:00:03 1970 +0000
228 files: b dir/b f g
228 files: b dir/b f g
229 description:
229 description:
230 c
230 c
231
231
232
232
233 changeset: 1:d89b0a12d229
233 changeset: 1:d89b0a12d229
234 user: test
234 user: test
235 date: Thu Jan 01 00:00:02 1970 +0000
235 date: Thu Jan 01 00:00:02 1970 +0000
236 files: b g
236 files: b g
237 description:
237 description:
238 b
238 b
239
239
240
240
241 changeset: 0:9161b9aeaf16
241 changeset: 0:9161b9aeaf16
242 user: test
242 user: test
243 date: Thu Jan 01 00:00:01 1970 +0000
243 date: Thu Jan 01 00:00:01 1970 +0000
244 files: a f
244 files: a f
245 description:
245 description:
246 a
246 a
247
247
248
248
249
249
250
250
251 log -pf dir/b
251 log -pf dir/b
252
252
253 $ hg up -q 3
253 $ hg up -q 3
254 $ hg log -pf dir/b
254 $ hg log -pf dir/b
255 changeset: 2:f8954cd4dc1f
255 changeset: 2:f8954cd4dc1f
256 user: test
256 user: test
257 date: Thu Jan 01 00:00:03 1970 +0000
257 date: Thu Jan 01 00:00:03 1970 +0000
258 summary: c
258 summary: c
259
259
260 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
260 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
261 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
261 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
262 +++ b/dir/b Thu Jan 01 00:00:03 1970 +0000
262 +++ b/dir/b Thu Jan 01 00:00:03 1970 +0000
263 @@ -0,0 +1,1 @@
263 @@ -0,0 +1,1 @@
264 +a
264 +a
265
265
266 changeset: 1:d89b0a12d229
266 changeset: 1:d89b0a12d229
267 user: test
267 user: test
268 date: Thu Jan 01 00:00:02 1970 +0000
268 date: Thu Jan 01 00:00:02 1970 +0000
269 summary: b
269 summary: b
270
270
271 diff -r 9161b9aeaf16 -r d89b0a12d229 b
271 diff -r 9161b9aeaf16 -r d89b0a12d229 b
272 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
272 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
273 +++ b/b Thu Jan 01 00:00:02 1970 +0000
273 +++ b/b Thu Jan 01 00:00:02 1970 +0000
274 @@ -0,0 +1,1 @@
274 @@ -0,0 +1,1 @@
275 +a
275 +a
276
276
277 changeset: 0:9161b9aeaf16
277 changeset: 0:9161b9aeaf16
278 user: test
278 user: test
279 date: Thu Jan 01 00:00:01 1970 +0000
279 date: Thu Jan 01 00:00:01 1970 +0000
280 summary: a
280 summary: a
281
281
282 diff -r 000000000000 -r 9161b9aeaf16 a
282 diff -r 000000000000 -r 9161b9aeaf16 a
283 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
283 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
284 +++ b/a Thu Jan 01 00:00:01 1970 +0000
284 +++ b/a Thu Jan 01 00:00:01 1970 +0000
285 @@ -0,0 +1,1 @@
285 @@ -0,0 +1,1 @@
286 +a
286 +a
287
287
288
288
289 log -pf b inside dir
289 log -pf b inside dir
290
290
291 $ hg --cwd=dir log -pf b
291 $ hg --cwd=dir log -pf b
292 changeset: 2:f8954cd4dc1f
292 changeset: 2:f8954cd4dc1f
293 user: test
293 user: test
294 date: Thu Jan 01 00:00:03 1970 +0000
294 date: Thu Jan 01 00:00:03 1970 +0000
295 summary: c
295 summary: c
296
296
297 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
297 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
298 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
298 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
299 +++ b/dir/b Thu Jan 01 00:00:03 1970 +0000
299 +++ b/dir/b Thu Jan 01 00:00:03 1970 +0000
300 @@ -0,0 +1,1 @@
300 @@ -0,0 +1,1 @@
301 +a
301 +a
302
302
303 changeset: 1:d89b0a12d229
303 changeset: 1:d89b0a12d229
304 user: test
304 user: test
305 date: Thu Jan 01 00:00:02 1970 +0000
305 date: Thu Jan 01 00:00:02 1970 +0000
306 summary: b
306 summary: b
307
307
308 diff -r 9161b9aeaf16 -r d89b0a12d229 b
308 diff -r 9161b9aeaf16 -r d89b0a12d229 b
309 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
309 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
310 +++ b/b Thu Jan 01 00:00:02 1970 +0000
310 +++ b/b Thu Jan 01 00:00:02 1970 +0000
311 @@ -0,0 +1,1 @@
311 @@ -0,0 +1,1 @@
312 +a
312 +a
313
313
314 changeset: 0:9161b9aeaf16
314 changeset: 0:9161b9aeaf16
315 user: test
315 user: test
316 date: Thu Jan 01 00:00:01 1970 +0000
316 date: Thu Jan 01 00:00:01 1970 +0000
317 summary: a
317 summary: a
318
318
319 diff -r 000000000000 -r 9161b9aeaf16 a
319 diff -r 000000000000 -r 9161b9aeaf16 a
320 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
320 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
321 +++ b/a Thu Jan 01 00:00:01 1970 +0000
321 +++ b/a Thu Jan 01 00:00:01 1970 +0000
322 @@ -0,0 +1,1 @@
322 @@ -0,0 +1,1 @@
323 +a
323 +a
324
324
325
325
326 log -pf, but no args
326 log -pf, but no args
327
327
328 $ hg log -pf
328 $ hg log -pf
329 changeset: 3:2ca5ba701980
329 changeset: 3:2ca5ba701980
330 user: test
330 user: test
331 date: Thu Jan 01 00:00:04 1970 +0000
331 date: Thu Jan 01 00:00:04 1970 +0000
332 summary: d
332 summary: d
333
333
334 diff -r f8954cd4dc1f -r 2ca5ba701980 a
334 diff -r f8954cd4dc1f -r 2ca5ba701980 a
335 --- a/a Thu Jan 01 00:00:03 1970 +0000
335 --- a/a Thu Jan 01 00:00:03 1970 +0000
336 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
336 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
337 @@ -1,1 +0,0 @@
337 @@ -1,1 +0,0 @@
338 -a
338 -a
339 diff -r f8954cd4dc1f -r 2ca5ba701980 b
339 diff -r f8954cd4dc1f -r 2ca5ba701980 b
340 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
340 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
341 +++ b/b Thu Jan 01 00:00:04 1970 +0000
341 +++ b/b Thu Jan 01 00:00:04 1970 +0000
342 @@ -0,0 +1,1 @@
342 @@ -0,0 +1,1 @@
343 +a
343 +a
344 diff -r f8954cd4dc1f -r 2ca5ba701980 d
344 diff -r f8954cd4dc1f -r 2ca5ba701980 d
345 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
345 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
346 +++ b/d Thu Jan 01 00:00:04 1970 +0000
346 +++ b/d Thu Jan 01 00:00:04 1970 +0000
347 @@ -0,0 +1,1 @@
347 @@ -0,0 +1,1 @@
348 +a
348 +a
349 diff -r f8954cd4dc1f -r 2ca5ba701980 g
349 diff -r f8954cd4dc1f -r 2ca5ba701980 g
350 --- a/g Thu Jan 01 00:00:03 1970 +0000
350 --- a/g Thu Jan 01 00:00:03 1970 +0000
351 +++ b/g Thu Jan 01 00:00:04 1970 +0000
351 +++ b/g Thu Jan 01 00:00:04 1970 +0000
352 @@ -1,2 +1,2 @@
352 @@ -1,2 +1,2 @@
353 f
353 f
354 -g
354 -g
355 +f
355 +f
356
356
357 changeset: 2:f8954cd4dc1f
357 changeset: 2:f8954cd4dc1f
358 user: test
358 user: test
359 date: Thu Jan 01 00:00:03 1970 +0000
359 date: Thu Jan 01 00:00:03 1970 +0000
360 summary: c
360 summary: c
361
361
362 diff -r d89b0a12d229 -r f8954cd4dc1f b
362 diff -r d89b0a12d229 -r f8954cd4dc1f b
363 --- a/b Thu Jan 01 00:00:02 1970 +0000
363 --- a/b Thu Jan 01 00:00:02 1970 +0000
364 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
364 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
365 @@ -1,1 +0,0 @@
365 @@ -1,1 +0,0 @@
366 -a
366 -a
367 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
367 diff -r d89b0a12d229 -r f8954cd4dc1f dir/b
368 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
368 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
369 +++ b/dir/b Thu Jan 01 00:00:03 1970 +0000
369 +++ b/dir/b Thu Jan 01 00:00:03 1970 +0000
370 @@ -0,0 +1,1 @@
370 @@ -0,0 +1,1 @@
371 +a
371 +a
372 diff -r d89b0a12d229 -r f8954cd4dc1f f
372 diff -r d89b0a12d229 -r f8954cd4dc1f f
373 --- a/f Thu Jan 01 00:00:02 1970 +0000
373 --- a/f Thu Jan 01 00:00:02 1970 +0000
374 +++ b/f Thu Jan 01 00:00:03 1970 +0000
374 +++ b/f Thu Jan 01 00:00:03 1970 +0000
375 @@ -1,1 +1,2 @@
375 @@ -1,1 +1,2 @@
376 f
376 f
377 +f
377 +f
378 diff -r d89b0a12d229 -r f8954cd4dc1f g
378 diff -r d89b0a12d229 -r f8954cd4dc1f g
379 --- a/g Thu Jan 01 00:00:02 1970 +0000
379 --- a/g Thu Jan 01 00:00:02 1970 +0000
380 +++ b/g Thu Jan 01 00:00:03 1970 +0000
380 +++ b/g Thu Jan 01 00:00:03 1970 +0000
381 @@ -1,1 +1,2 @@
381 @@ -1,1 +1,2 @@
382 f
382 f
383 +g
383 +g
384
384
385 changeset: 1:d89b0a12d229
385 changeset: 1:d89b0a12d229
386 user: test
386 user: test
387 date: Thu Jan 01 00:00:02 1970 +0000
387 date: Thu Jan 01 00:00:02 1970 +0000
388 summary: b
388 summary: b
389
389
390 diff -r 9161b9aeaf16 -r d89b0a12d229 b
390 diff -r 9161b9aeaf16 -r d89b0a12d229 b
391 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
391 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
392 +++ b/b Thu Jan 01 00:00:02 1970 +0000
392 +++ b/b Thu Jan 01 00:00:02 1970 +0000
393 @@ -0,0 +1,1 @@
393 @@ -0,0 +1,1 @@
394 +a
394 +a
395 diff -r 9161b9aeaf16 -r d89b0a12d229 g
395 diff -r 9161b9aeaf16 -r d89b0a12d229 g
396 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
396 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
397 +++ b/g Thu Jan 01 00:00:02 1970 +0000
397 +++ b/g Thu Jan 01 00:00:02 1970 +0000
398 @@ -0,0 +1,1 @@
398 @@ -0,0 +1,1 @@
399 +f
399 +f
400
400
401 changeset: 0:9161b9aeaf16
401 changeset: 0:9161b9aeaf16
402 user: test
402 user: test
403 date: Thu Jan 01 00:00:01 1970 +0000
403 date: Thu Jan 01 00:00:01 1970 +0000
404 summary: a
404 summary: a
405
405
406 diff -r 000000000000 -r 9161b9aeaf16 a
406 diff -r 000000000000 -r 9161b9aeaf16 a
407 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
407 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
408 +++ b/a Thu Jan 01 00:00:01 1970 +0000
408 +++ b/a Thu Jan 01 00:00:01 1970 +0000
409 @@ -0,0 +1,1 @@
409 @@ -0,0 +1,1 @@
410 +a
410 +a
411 diff -r 000000000000 -r 9161b9aeaf16 f
411 diff -r 000000000000 -r 9161b9aeaf16 f
412 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
412 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
413 +++ b/f Thu Jan 01 00:00:01 1970 +0000
413 +++ b/f Thu Jan 01 00:00:01 1970 +0000
414 @@ -0,0 +1,1 @@
414 @@ -0,0 +1,1 @@
415 +f
415 +f
416
416
417
417
418 log -vf dir/b
418 log -vf dir/b
419
419
420 $ hg log -vf dir/b
420 $ hg log -vf dir/b
421 changeset: 2:f8954cd4dc1f
421 changeset: 2:f8954cd4dc1f
422 user: test
422 user: test
423 date: Thu Jan 01 00:00:03 1970 +0000
423 date: Thu Jan 01 00:00:03 1970 +0000
424 files: b dir/b f g
424 files: b dir/b f g
425 description:
425 description:
426 c
426 c
427
427
428
428
429 changeset: 1:d89b0a12d229
429 changeset: 1:d89b0a12d229
430 user: test
430 user: test
431 date: Thu Jan 01 00:00:02 1970 +0000
431 date: Thu Jan 01 00:00:02 1970 +0000
432 files: b g
432 files: b g
433 description:
433 description:
434 b
434 b
435
435
436
436
437 changeset: 0:9161b9aeaf16
437 changeset: 0:9161b9aeaf16
438 user: test
438 user: test
439 date: Thu Jan 01 00:00:01 1970 +0000
439 date: Thu Jan 01 00:00:01 1970 +0000
440 files: a f
440 files: a f
441 description:
441 description:
442 a
442 a
443
443
444
444
445
445
446
446
447 -f and multiple filelog heads
447 -f and multiple filelog heads
448
448
449 $ hg up -q 2
449 $ hg up -q 2
450 $ hg log -f g --template '{rev}\n'
450 $ hg log -f g --template '{rev}\n'
451 2
451 2
452 1
452 1
453 0
453 0
454 $ hg up -q tip
454 $ hg up -q tip
455 $ hg log -f g --template '{rev}\n'
455 $ hg log -f g --template '{rev}\n'
456 3
456 3
457 2
457 2
458 0
458 0
459
459
460
460
461 log copies with --copies
461 log copies with --copies
462
462
463 $ hg log -vC --template '{rev} {file_copies}\n'
463 $ hg log -vC --template '{rev} {file_copies}\n'
464 4 e (dir/b)
464 4 e (dir/b)
465 3 b (a)g (f)
465 3 b (a)g (f)
466 2 dir/b (b)
466 2 dir/b (b)
467 1 b (a)g (f)
467 1 b (a)g (f)
468 0
468 0
469
469
470 log copies switch without --copies, with old filecopy template
470 log copies switch without --copies, with old filecopy template
471
471
472 $ hg log -v --template '{rev} {file_copies_switch%filecopy}\n'
472 $ hg log -v --template '{rev} {file_copies_switch%filecopy}\n'
473 4
473 4
474 3
474 3
475 2
475 2
476 1
476 1
477 0
477 0
478
478
479 log copies switch with --copies
479 log copies switch with --copies
480
480
481 $ hg log -vC --template '{rev} {file_copies_switch}\n'
481 $ hg log -vC --template '{rev} {file_copies_switch}\n'
482 4 e (dir/b)
482 4 e (dir/b)
483 3 b (a)g (f)
483 3 b (a)g (f)
484 2 dir/b (b)
484 2 dir/b (b)
485 1 b (a)g (f)
485 1 b (a)g (f)
486 0
486 0
487
487
488
488
489 log copies with hardcoded style and with --style=default
489 log copies with hardcoded style and with --style=default
490
490
491 $ hg log -vC -r4
491 $ hg log -vC -r4
492 changeset: 4:7e4639b4691b
492 changeset: 4:7e4639b4691b
493 tag: tip
493 tag: tip
494 user: test
494 user: test
495 date: Thu Jan 01 00:00:05 1970 +0000
495 date: Thu Jan 01 00:00:05 1970 +0000
496 files: dir/b e
496 files: dir/b e
497 copies: e (dir/b)
497 copies: e (dir/b)
498 description:
498 description:
499 e
499 e
500
500
501
501
502 $ hg log -vC -r4 --style=default
502 $ hg log -vC -r4 --style=default
503 changeset: 4:7e4639b4691b
503 changeset: 4:7e4639b4691b
504 tag: tip
504 tag: tip
505 user: test
505 user: test
506 date: Thu Jan 01 00:00:05 1970 +0000
506 date: Thu Jan 01 00:00:05 1970 +0000
507 files: dir/b e
507 files: dir/b e
508 copies: e (dir/b)
508 copies: e (dir/b)
509 description:
509 description:
510 e
510 e
511
511
512
512
513 $ hg log -vC -r4 -Tjson
513 $ hg log -vC -r4 -Tjson
514 [
514 [
515 {
515 {
516 "rev": 4,
516 "rev": 4,
517 "node": "7e4639b4691b9f84b81036a8d4fb218ce3c5e3a3",
517 "node": "7e4639b4691b9f84b81036a8d4fb218ce3c5e3a3",
518 "branch": "default",
518 "branch": "default",
519 "phase": "draft",
519 "phase": "draft",
520 "user": "test",
520 "user": "test",
521 "date": [5, 0],
521 "date": [5, 0],
522 "desc": "e",
522 "desc": "e",
523 "bookmarks": [],
523 "bookmarks": [],
524 "tags": ["tip"],
524 "tags": ["tip"],
525 "parents": ["2ca5ba7019804f1f597249caddf22a64d34df0ba"],
525 "parents": ["2ca5ba7019804f1f597249caddf22a64d34df0ba"],
526 "files": ["dir/b", "e"],
526 "files": ["dir/b", "e"],
527 "copies": {"e": "dir/b"}
527 "copies": {"e": "dir/b"}
528 }
528 }
529 ]
529 ]
530
530
531 log copies, non-linear manifest
531 log copies, non-linear manifest
532
532
533 $ hg up -C 3
533 $ hg up -C 3
534 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
534 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
535 $ hg mv dir/b e
535 $ hg mv dir/b e
536 $ echo foo > foo
536 $ echo foo > foo
537 $ hg ci -Ame2 -d '6 0'
537 $ hg ci -Ame2 -d '6 0'
538 adding foo
538 adding foo
539 created new head
539 created new head
540 $ hg log -v --template '{rev} {file_copies}\n' -r 5
540 $ hg log -v --template '{rev} {file_copies}\n' -r 5
541 5 e (dir/b)
541 5 e (dir/b)
542
542
543
543
544 log copies, execute bit set
544 log copies, execute bit set
545
545
546 #if execbit
546 #if execbit
547 $ chmod +x e
547 $ chmod +x e
548 $ hg ci -me3 -d '7 0'
548 $ hg ci -me3 -d '7 0'
549 $ hg log -v --template '{rev} {file_copies}\n' -r 6
549 $ hg log -v --template '{rev} {file_copies}\n' -r 6
550 6
550 6
551 #endif
551 #endif
552
552
553
553
554 log -p d
554 log -p d
555
555
556 $ hg log -pv d
556 $ hg log -pv d
557 changeset: 3:2ca5ba701980
557 changeset: 3:2ca5ba701980
558 user: test
558 user: test
559 date: Thu Jan 01 00:00:04 1970 +0000
559 date: Thu Jan 01 00:00:04 1970 +0000
560 files: a b d g
560 files: a b d g
561 description:
561 description:
562 d
562 d
563
563
564
564
565 diff -r f8954cd4dc1f -r 2ca5ba701980 d
565 diff -r f8954cd4dc1f -r 2ca5ba701980 d
566 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
566 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
567 +++ b/d Thu Jan 01 00:00:04 1970 +0000
567 +++ b/d Thu Jan 01 00:00:04 1970 +0000
568 @@ -0,0 +1,1 @@
568 @@ -0,0 +1,1 @@
569 +a
569 +a
570
570
571
571
572
572
573 log --removed file
573 log --removed file
574
574
575 $ hg log --removed -v a
575 $ hg log --removed -v a
576 changeset: 3:2ca5ba701980
576 changeset: 3:2ca5ba701980
577 user: test
577 user: test
578 date: Thu Jan 01 00:00:04 1970 +0000
578 date: Thu Jan 01 00:00:04 1970 +0000
579 files: a b d g
579 files: a b d g
580 description:
580 description:
581 d
581 d
582
582
583
583
584 changeset: 0:9161b9aeaf16
584 changeset: 0:9161b9aeaf16
585 user: test
585 user: test
586 date: Thu Jan 01 00:00:01 1970 +0000
586 date: Thu Jan 01 00:00:01 1970 +0000
587 files: a f
587 files: a f
588 description:
588 description:
589 a
589 a
590
590
591
591
592
592
593 log --removed revrange file
593 log --removed revrange file
594
594
595 $ hg log --removed -v -r0:2 a
595 $ hg log --removed -v -r0:2 a
596 changeset: 0:9161b9aeaf16
596 changeset: 0:9161b9aeaf16
597 user: test
597 user: test
598 date: Thu Jan 01 00:00:01 1970 +0000
598 date: Thu Jan 01 00:00:01 1970 +0000
599 files: a f
599 files: a f
600 description:
600 description:
601 a
601 a
602
602
603
603
604 $ cd ..
604 $ cd ..
605
605
606 log --follow tests
606 log --follow tests
607
607
608 $ hg init follow
608 $ hg init follow
609 $ cd follow
609 $ cd follow
610
610
611 $ echo base > base
611 $ echo base > base
612 $ hg ci -Ambase -d '1 0'
612 $ hg ci -Ambase -d '1 0'
613 adding base
613 adding base
614
614
615 $ echo r1 >> base
615 $ echo r1 >> base
616 $ hg ci -Amr1 -d '1 0'
616 $ hg ci -Amr1 -d '1 0'
617 $ echo r2 >> base
617 $ echo r2 >> base
618 $ hg ci -Amr2 -d '1 0'
618 $ hg ci -Amr2 -d '1 0'
619
619
620 $ hg up -C 1
620 $ hg up -C 1
621 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
621 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
622 $ echo b1 > b1
622 $ echo b1 > b1
623 $ hg ci -Amb1 -d '1 0'
623 $ hg ci -Amb1 -d '1 0'
624 adding b1
624 adding b1
625 created new head
625 created new head
626
626
627
627
628 log -f
628 log -f
629
629
630 $ hg log -f
630 $ hg log -f
631 changeset: 3:e62f78d544b4
631 changeset: 3:e62f78d544b4
632 tag: tip
632 tag: tip
633 parent: 1:3d5bf5654eda
633 parent: 1:3d5bf5654eda
634 user: test
634 user: test
635 date: Thu Jan 01 00:00:01 1970 +0000
635 date: Thu Jan 01 00:00:01 1970 +0000
636 summary: b1
636 summary: b1
637
637
638 changeset: 1:3d5bf5654eda
638 changeset: 1:3d5bf5654eda
639 user: test
639 user: test
640 date: Thu Jan 01 00:00:01 1970 +0000
640 date: Thu Jan 01 00:00:01 1970 +0000
641 summary: r1
641 summary: r1
642
642
643 changeset: 0:67e992f2c4f3
643 changeset: 0:67e992f2c4f3
644 user: test
644 user: test
645 date: Thu Jan 01 00:00:01 1970 +0000
645 date: Thu Jan 01 00:00:01 1970 +0000
646 summary: base
646 summary: base
647
647
648
648
649
649
650 log -f -r '1 + 4'
650 log -f -r '1 + 4'
651
651
652 $ hg up -C 0
652 $ hg up -C 0
653 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
653 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
654 $ echo b2 > b2
654 $ echo b2 > b2
655 $ hg ci -Amb2 -d '1 0'
655 $ hg ci -Amb2 -d '1 0'
656 adding b2
656 adding b2
657 created new head
657 created new head
658 $ hg log -f -r '1 + 4'
658 $ hg log -f -r '1 + 4'
659 changeset: 4:ddb82e70d1a1
659 changeset: 4:ddb82e70d1a1
660 tag: tip
660 tag: tip
661 parent: 0:67e992f2c4f3
661 parent: 0:67e992f2c4f3
662 user: test
662 user: test
663 date: Thu Jan 01 00:00:01 1970 +0000
663 date: Thu Jan 01 00:00:01 1970 +0000
664 summary: b2
664 summary: b2
665
665
666 changeset: 1:3d5bf5654eda
666 changeset: 1:3d5bf5654eda
667 user: test
667 user: test
668 date: Thu Jan 01 00:00:01 1970 +0000
668 date: Thu Jan 01 00:00:01 1970 +0000
669 summary: r1
669 summary: r1
670
670
671 changeset: 0:67e992f2c4f3
671 changeset: 0:67e992f2c4f3
672 user: test
672 user: test
673 date: Thu Jan 01 00:00:01 1970 +0000
673 date: Thu Jan 01 00:00:01 1970 +0000
674 summary: base
674 summary: base
675
675
676 log -f -r null
676 log -f -r null
677
677
678 $ hg log -f -r null
678 $ hg log -f -r null
679 changeset: -1:000000000000
679 changeset: -1:000000000000
680 user:
680 user:
681 date: Thu Jan 01 00:00:00 1970 +0000
681 date: Thu Jan 01 00:00:00 1970 +0000
682
682
683 $ hg log -f -r null -G
683 $ hg log -f -r null -G
684 o changeset: -1:000000000000
684 o changeset: -1:000000000000
685 user:
685 user:
686 date: Thu Jan 01 00:00:00 1970 +0000
686 date: Thu Jan 01 00:00:00 1970 +0000
687
687
688
688
689
689
690 log -f with null parent
690 log -f with null parent
691
691
692 $ hg up -C null
692 $ hg up -C null
693 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
693 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
694 $ hg log -f
694 $ hg log -f
695
695
696
696
697 log -r . with two parents
697 log -r . with two parents
698
698
699 $ hg up -C 3
699 $ hg up -C 3
700 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
700 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
701 $ hg merge tip
701 $ hg merge tip
702 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
702 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
703 (branch merge, don't forget to commit)
703 (branch merge, don't forget to commit)
704 $ hg log -r .
704 $ hg log -r .
705 changeset: 3:e62f78d544b4
705 changeset: 3:e62f78d544b4
706 parent: 1:3d5bf5654eda
706 parent: 1:3d5bf5654eda
707 user: test
707 user: test
708 date: Thu Jan 01 00:00:01 1970 +0000
708 date: Thu Jan 01 00:00:01 1970 +0000
709 summary: b1
709 summary: b1
710
710
711
711
712
712
713 log -r . with one parent
713 log -r . with one parent
714
714
715 $ hg ci -mm12 -d '1 0'
715 $ hg ci -mm12 -d '1 0'
716 $ hg log -r .
716 $ hg log -r .
717 changeset: 5:302e9dd6890d
717 changeset: 5:302e9dd6890d
718 tag: tip
718 tag: tip
719 parent: 3:e62f78d544b4
719 parent: 3:e62f78d544b4
720 parent: 4:ddb82e70d1a1
720 parent: 4:ddb82e70d1a1
721 user: test
721 user: test
722 date: Thu Jan 01 00:00:01 1970 +0000
722 date: Thu Jan 01 00:00:01 1970 +0000
723 summary: m12
723 summary: m12
724
724
725
725
726 $ echo postm >> b1
726 $ echo postm >> b1
727 $ hg ci -Amb1.1 -d'1 0'
727 $ hg ci -Amb1.1 -d'1 0'
728
728
729
729
730 log --follow-first
730 log --follow-first
731
731
732 $ hg log --follow-first
732 $ hg log --follow-first
733 changeset: 6:2404bbcab562
733 changeset: 6:2404bbcab562
734 tag: tip
734 tag: tip
735 user: test
735 user: test
736 date: Thu Jan 01 00:00:01 1970 +0000
736 date: Thu Jan 01 00:00:01 1970 +0000
737 summary: b1.1
737 summary: b1.1
738
738
739 changeset: 5:302e9dd6890d
739 changeset: 5:302e9dd6890d
740 parent: 3:e62f78d544b4
740 parent: 3:e62f78d544b4
741 parent: 4:ddb82e70d1a1
741 parent: 4:ddb82e70d1a1
742 user: test
742 user: test
743 date: Thu Jan 01 00:00:01 1970 +0000
743 date: Thu Jan 01 00:00:01 1970 +0000
744 summary: m12
744 summary: m12
745
745
746 changeset: 3:e62f78d544b4
746 changeset: 3:e62f78d544b4
747 parent: 1:3d5bf5654eda
747 parent: 1:3d5bf5654eda
748 user: test
748 user: test
749 date: Thu Jan 01 00:00:01 1970 +0000
749 date: Thu Jan 01 00:00:01 1970 +0000
750 summary: b1
750 summary: b1
751
751
752 changeset: 1:3d5bf5654eda
752 changeset: 1:3d5bf5654eda
753 user: test
753 user: test
754 date: Thu Jan 01 00:00:01 1970 +0000
754 date: Thu Jan 01 00:00:01 1970 +0000
755 summary: r1
755 summary: r1
756
756
757 changeset: 0:67e992f2c4f3
757 changeset: 0:67e992f2c4f3
758 user: test
758 user: test
759 date: Thu Jan 01 00:00:01 1970 +0000
759 date: Thu Jan 01 00:00:01 1970 +0000
760 summary: base
760 summary: base
761
761
762
762
763
763
764 log -P 2
764 log -P 2
765
765
766 $ hg log -P 2
766 $ hg log -P 2
767 changeset: 6:2404bbcab562
767 changeset: 6:2404bbcab562
768 tag: tip
768 tag: tip
769 user: test
769 user: test
770 date: Thu Jan 01 00:00:01 1970 +0000
770 date: Thu Jan 01 00:00:01 1970 +0000
771 summary: b1.1
771 summary: b1.1
772
772
773 changeset: 5:302e9dd6890d
773 changeset: 5:302e9dd6890d
774 parent: 3:e62f78d544b4
774 parent: 3:e62f78d544b4
775 parent: 4:ddb82e70d1a1
775 parent: 4:ddb82e70d1a1
776 user: test
776 user: test
777 date: Thu Jan 01 00:00:01 1970 +0000
777 date: Thu Jan 01 00:00:01 1970 +0000
778 summary: m12
778 summary: m12
779
779
780 changeset: 4:ddb82e70d1a1
780 changeset: 4:ddb82e70d1a1
781 parent: 0:67e992f2c4f3
781 parent: 0:67e992f2c4f3
782 user: test
782 user: test
783 date: Thu Jan 01 00:00:01 1970 +0000
783 date: Thu Jan 01 00:00:01 1970 +0000
784 summary: b2
784 summary: b2
785
785
786 changeset: 3:e62f78d544b4
786 changeset: 3:e62f78d544b4
787 parent: 1:3d5bf5654eda
787 parent: 1:3d5bf5654eda
788 user: test
788 user: test
789 date: Thu Jan 01 00:00:01 1970 +0000
789 date: Thu Jan 01 00:00:01 1970 +0000
790 summary: b1
790 summary: b1
791
791
792
792
793
793
794 log -r tip -p --git
794 log -r tip -p --git
795
795
796 $ hg log -r tip -p --git
796 $ hg log -r tip -p --git
797 changeset: 6:2404bbcab562
797 changeset: 6:2404bbcab562
798 tag: tip
798 tag: tip
799 user: test
799 user: test
800 date: Thu Jan 01 00:00:01 1970 +0000
800 date: Thu Jan 01 00:00:01 1970 +0000
801 summary: b1.1
801 summary: b1.1
802
802
803 diff --git a/b1 b/b1
803 diff --git a/b1 b/b1
804 --- a/b1
804 --- a/b1
805 +++ b/b1
805 +++ b/b1
806 @@ -1,1 +1,2 @@
806 @@ -1,1 +1,2 @@
807 b1
807 b1
808 +postm
808 +postm
809
809
810
810
811
811
812 log -r ""
812 log -r ""
813
813
814 $ hg log -r ''
814 $ hg log -r ''
815 hg: parse error: empty query
815 hg: parse error: empty query
816 [255]
816 [255]
817
817
818 log -r <some unknown node id>
818 log -r <some unknown node id>
819
819
820 $ hg log -r 1000000000000000000000000000000000000000
820 $ hg log -r 1000000000000000000000000000000000000000
821 abort: unknown revision '1000000000000000000000000000000000000000'!
821 abort: unknown revision '1000000000000000000000000000000000000000'!
822 [255]
822 [255]
823
823
824 log -k r1
824 log -k r1
825
825
826 $ hg log -k r1
826 $ hg log -k r1
827 changeset: 1:3d5bf5654eda
827 changeset: 1:3d5bf5654eda
828 user: test
828 user: test
829 date: Thu Jan 01 00:00:01 1970 +0000
829 date: Thu Jan 01 00:00:01 1970 +0000
830 summary: r1
830 summary: r1
831
831
832 log -p -l2 --color=always
832 log -p -l2 --color=always
833
833
834 $ hg --config extensions.color= --config color.mode=ansi \
834 $ hg --config extensions.color= --config color.mode=ansi \
835 > log -p -l2 --color=always
835 > log -p -l2 --color=always
836 \x1b[0;33mchangeset: 6:2404bbcab562\x1b[0m (esc)
836 \x1b[0;33mchangeset: 6:2404bbcab562\x1b[0m (esc)
837 tag: tip
837 tag: tip
838 user: test
838 user: test
839 date: Thu Jan 01 00:00:01 1970 +0000
839 date: Thu Jan 01 00:00:01 1970 +0000
840 summary: b1.1
840 summary: b1.1
841
841
842 \x1b[0;1mdiff -r 302e9dd6890d -r 2404bbcab562 b1\x1b[0m (esc)
842 \x1b[0;1mdiff -r 302e9dd6890d -r 2404bbcab562 b1\x1b[0m (esc)
843 \x1b[0;31;1m--- a/b1 Thu Jan 01 00:00:01 1970 +0000\x1b[0m (esc)
843 \x1b[0;31;1m--- a/b1 Thu Jan 01 00:00:01 1970 +0000\x1b[0m (esc)
844 \x1b[0;32;1m+++ b/b1 Thu Jan 01 00:00:01 1970 +0000\x1b[0m (esc)
844 \x1b[0;32;1m+++ b/b1 Thu Jan 01 00:00:01 1970 +0000\x1b[0m (esc)
845 \x1b[0;35m@@ -1,1 +1,2 @@\x1b[0m (esc)
845 \x1b[0;35m@@ -1,1 +1,2 @@\x1b[0m (esc)
846 b1
846 b1
847 \x1b[0;32m+postm\x1b[0m (esc)
847 \x1b[0;32m+postm\x1b[0m (esc)
848
848
849 \x1b[0;33mchangeset: 5:302e9dd6890d\x1b[0m (esc)
849 \x1b[0;33mchangeset: 5:302e9dd6890d\x1b[0m (esc)
850 parent: 3:e62f78d544b4
850 parent: 3:e62f78d544b4
851 parent: 4:ddb82e70d1a1
851 parent: 4:ddb82e70d1a1
852 user: test
852 user: test
853 date: Thu Jan 01 00:00:01 1970 +0000
853 date: Thu Jan 01 00:00:01 1970 +0000
854 summary: m12
854 summary: m12
855
855
856 \x1b[0;1mdiff -r e62f78d544b4 -r 302e9dd6890d b2\x1b[0m (esc)
856 \x1b[0;1mdiff -r e62f78d544b4 -r 302e9dd6890d b2\x1b[0m (esc)
857 \x1b[0;31;1m--- /dev/null Thu Jan 01 00:00:00 1970 +0000\x1b[0m (esc)
857 \x1b[0;31;1m--- /dev/null Thu Jan 01 00:00:00 1970 +0000\x1b[0m (esc)
858 \x1b[0;32;1m+++ b/b2 Thu Jan 01 00:00:01 1970 +0000\x1b[0m (esc)
858 \x1b[0;32;1m+++ b/b2 Thu Jan 01 00:00:01 1970 +0000\x1b[0m (esc)
859 \x1b[0;35m@@ -0,0 +1,1 @@\x1b[0m (esc)
859 \x1b[0;35m@@ -0,0 +1,1 @@\x1b[0m (esc)
860 \x1b[0;32m+b2\x1b[0m (esc)
860 \x1b[0;32m+b2\x1b[0m (esc)
861
861
862
862
863
863
864 log -r tip --stat
864 log -r tip --stat
865
865
866 $ hg log -r tip --stat
866 $ hg log -r tip --stat
867 changeset: 6:2404bbcab562
867 changeset: 6:2404bbcab562
868 tag: tip
868 tag: tip
869 user: test
869 user: test
870 date: Thu Jan 01 00:00:01 1970 +0000
870 date: Thu Jan 01 00:00:01 1970 +0000
871 summary: b1.1
871 summary: b1.1
872
872
873 b1 | 1 +
873 b1 | 1 +
874 1 files changed, 1 insertions(+), 0 deletions(-)
874 1 files changed, 1 insertions(+), 0 deletions(-)
875
875
876
876
877 $ cd ..
877 $ cd ..
878
878
879
879
880 User
880 User
881
881
882 $ hg init usertest
882 $ hg init usertest
883 $ cd usertest
883 $ cd usertest
884
884
885 $ echo a > a
885 $ echo a > a
886 $ hg ci -A -m "a" -u "User One <user1@example.org>"
886 $ hg ci -A -m "a" -u "User One <user1@example.org>"
887 adding a
887 adding a
888 $ echo b > b
888 $ echo b > b
889 $ hg ci -A -m "b" -u "User Two <user2@example.org>"
889 $ hg ci -A -m "b" -u "User Two <user2@example.org>"
890 adding b
890 adding b
891
891
892 $ hg log -u "User One <user1@example.org>"
892 $ hg log -u "User One <user1@example.org>"
893 changeset: 0:29a4c94f1924
893 changeset: 0:29a4c94f1924
894 user: User One <user1@example.org>
894 user: User One <user1@example.org>
895 date: Thu Jan 01 00:00:00 1970 +0000
895 date: Thu Jan 01 00:00:00 1970 +0000
896 summary: a
896 summary: a
897
897
898 $ hg log -u "user1" -u "user2"
898 $ hg log -u "user1" -u "user2"
899 changeset: 1:e834b5e69c0e
899 changeset: 1:e834b5e69c0e
900 tag: tip
900 tag: tip
901 user: User Two <user2@example.org>
901 user: User Two <user2@example.org>
902 date: Thu Jan 01 00:00:00 1970 +0000
902 date: Thu Jan 01 00:00:00 1970 +0000
903 summary: b
903 summary: b
904
904
905 changeset: 0:29a4c94f1924
905 changeset: 0:29a4c94f1924
906 user: User One <user1@example.org>
906 user: User One <user1@example.org>
907 date: Thu Jan 01 00:00:00 1970 +0000
907 date: Thu Jan 01 00:00:00 1970 +0000
908 summary: a
908 summary: a
909
909
910 $ hg log -u "user3"
910 $ hg log -u "user3"
911
911
912 $ cd ..
912 $ cd ..
913
913
914 $ hg init branches
914 $ hg init branches
915 $ cd branches
915 $ cd branches
916
916
917 $ echo a > a
917 $ echo a > a
918 $ hg ci -A -m "commit on default"
918 $ hg ci -A -m "commit on default"
919 adding a
919 adding a
920 $ hg branch test
920 $ hg branch test
921 marked working directory as branch test
921 marked working directory as branch test
922 (branches are permanent and global, did you want a bookmark?)
922 (branches are permanent and global, did you want a bookmark?)
923 $ echo b > b
923 $ echo b > b
924 $ hg ci -A -m "commit on test"
924 $ hg ci -A -m "commit on test"
925 adding b
925 adding b
926
926
927 $ hg up default
927 $ hg up default
928 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
928 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
929 $ echo c > c
929 $ echo c > c
930 $ hg ci -A -m "commit on default"
930 $ hg ci -A -m "commit on default"
931 adding c
931 adding c
932 $ hg up test
932 $ hg up test
933 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
933 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
934 $ echo c > c
934 $ echo c > c
935 $ hg ci -A -m "commit on test"
935 $ hg ci -A -m "commit on test"
936 adding c
936 adding c
937
937
938
938
939 log -b default
939 log -b default
940
940
941 $ hg log -b default
941 $ hg log -b default
942 changeset: 2:c3a4f03cc9a7
942 changeset: 2:c3a4f03cc9a7
943 parent: 0:24427303d56f
943 parent: 0:24427303d56f
944 user: test
944 user: test
945 date: Thu Jan 01 00:00:00 1970 +0000
945 date: Thu Jan 01 00:00:00 1970 +0000
946 summary: commit on default
946 summary: commit on default
947
947
948 changeset: 0:24427303d56f
948 changeset: 0:24427303d56f
949 user: test
949 user: test
950 date: Thu Jan 01 00:00:00 1970 +0000
950 date: Thu Jan 01 00:00:00 1970 +0000
951 summary: commit on default
951 summary: commit on default
952
952
953
953
954
954
955 log -b test
955 log -b test
956
956
957 $ hg log -b test
957 $ hg log -b test
958 changeset: 3:f5d8de11c2e2
958 changeset: 3:f5d8de11c2e2
959 branch: test
959 branch: test
960 tag: tip
960 tag: tip
961 parent: 1:d32277701ccb
961 parent: 1:d32277701ccb
962 user: test
962 user: test
963 date: Thu Jan 01 00:00:00 1970 +0000
963 date: Thu Jan 01 00:00:00 1970 +0000
964 summary: commit on test
964 summary: commit on test
965
965
966 changeset: 1:d32277701ccb
966 changeset: 1:d32277701ccb
967 branch: test
967 branch: test
968 user: test
968 user: test
969 date: Thu Jan 01 00:00:00 1970 +0000
969 date: Thu Jan 01 00:00:00 1970 +0000
970 summary: commit on test
970 summary: commit on test
971
971
972
972
973
973
974 log -b dummy
974 log -b dummy
975
975
976 $ hg log -b dummy
976 $ hg log -b dummy
977 abort: unknown revision 'dummy'!
977 abort: unknown revision 'dummy'!
978 [255]
978 [255]
979
979
980
980
981 log -b .
981 log -b .
982
982
983 $ hg log -b .
983 $ hg log -b .
984 changeset: 3:f5d8de11c2e2
984 changeset: 3:f5d8de11c2e2
985 branch: test
985 branch: test
986 tag: tip
986 tag: tip
987 parent: 1:d32277701ccb
987 parent: 1:d32277701ccb
988 user: test
988 user: test
989 date: Thu Jan 01 00:00:00 1970 +0000
989 date: Thu Jan 01 00:00:00 1970 +0000
990 summary: commit on test
990 summary: commit on test
991
991
992 changeset: 1:d32277701ccb
992 changeset: 1:d32277701ccb
993 branch: test
993 branch: test
994 user: test
994 user: test
995 date: Thu Jan 01 00:00:00 1970 +0000
995 date: Thu Jan 01 00:00:00 1970 +0000
996 summary: commit on test
996 summary: commit on test
997
997
998
998
999
999
1000 log -b default -b test
1000 log -b default -b test
1001
1001
1002 $ hg log -b default -b test
1002 $ hg log -b default -b test
1003 changeset: 3:f5d8de11c2e2
1003 changeset: 3:f5d8de11c2e2
1004 branch: test
1004 branch: test
1005 tag: tip
1005 tag: tip
1006 parent: 1:d32277701ccb
1006 parent: 1:d32277701ccb
1007 user: test
1007 user: test
1008 date: Thu Jan 01 00:00:00 1970 +0000
1008 date: Thu Jan 01 00:00:00 1970 +0000
1009 summary: commit on test
1009 summary: commit on test
1010
1010
1011 changeset: 2:c3a4f03cc9a7
1011 changeset: 2:c3a4f03cc9a7
1012 parent: 0:24427303d56f
1012 parent: 0:24427303d56f
1013 user: test
1013 user: test
1014 date: Thu Jan 01 00:00:00 1970 +0000
1014 date: Thu Jan 01 00:00:00 1970 +0000
1015 summary: commit on default
1015 summary: commit on default
1016
1016
1017 changeset: 1:d32277701ccb
1017 changeset: 1:d32277701ccb
1018 branch: test
1018 branch: test
1019 user: test
1019 user: test
1020 date: Thu Jan 01 00:00:00 1970 +0000
1020 date: Thu Jan 01 00:00:00 1970 +0000
1021 summary: commit on test
1021 summary: commit on test
1022
1022
1023 changeset: 0:24427303d56f
1023 changeset: 0:24427303d56f
1024 user: test
1024 user: test
1025 date: Thu Jan 01 00:00:00 1970 +0000
1025 date: Thu Jan 01 00:00:00 1970 +0000
1026 summary: commit on default
1026 summary: commit on default
1027
1027
1028
1028
1029
1029
1030 log -b default -b .
1030 log -b default -b .
1031
1031
1032 $ hg log -b default -b .
1032 $ hg log -b default -b .
1033 changeset: 3:f5d8de11c2e2
1033 changeset: 3:f5d8de11c2e2
1034 branch: test
1034 branch: test
1035 tag: tip
1035 tag: tip
1036 parent: 1:d32277701ccb
1036 parent: 1:d32277701ccb
1037 user: test
1037 user: test
1038 date: Thu Jan 01 00:00:00 1970 +0000
1038 date: Thu Jan 01 00:00:00 1970 +0000
1039 summary: commit on test
1039 summary: commit on test
1040
1040
1041 changeset: 2:c3a4f03cc9a7
1041 changeset: 2:c3a4f03cc9a7
1042 parent: 0:24427303d56f
1042 parent: 0:24427303d56f
1043 user: test
1043 user: test
1044 date: Thu Jan 01 00:00:00 1970 +0000
1044 date: Thu Jan 01 00:00:00 1970 +0000
1045 summary: commit on default
1045 summary: commit on default
1046
1046
1047 changeset: 1:d32277701ccb
1047 changeset: 1:d32277701ccb
1048 branch: test
1048 branch: test
1049 user: test
1049 user: test
1050 date: Thu Jan 01 00:00:00 1970 +0000
1050 date: Thu Jan 01 00:00:00 1970 +0000
1051 summary: commit on test
1051 summary: commit on test
1052
1052
1053 changeset: 0:24427303d56f
1053 changeset: 0:24427303d56f
1054 user: test
1054 user: test
1055 date: Thu Jan 01 00:00:00 1970 +0000
1055 date: Thu Jan 01 00:00:00 1970 +0000
1056 summary: commit on default
1056 summary: commit on default
1057
1057
1058
1058
1059
1059
1060 log -b . -b test
1060 log -b . -b test
1061
1061
1062 $ hg log -b . -b test
1062 $ hg log -b . -b test
1063 changeset: 3:f5d8de11c2e2
1063 changeset: 3:f5d8de11c2e2
1064 branch: test
1064 branch: test
1065 tag: tip
1065 tag: tip
1066 parent: 1:d32277701ccb
1066 parent: 1:d32277701ccb
1067 user: test
1067 user: test
1068 date: Thu Jan 01 00:00:00 1970 +0000
1068 date: Thu Jan 01 00:00:00 1970 +0000
1069 summary: commit on test
1069 summary: commit on test
1070
1070
1071 changeset: 1:d32277701ccb
1071 changeset: 1:d32277701ccb
1072 branch: test
1072 branch: test
1073 user: test
1073 user: test
1074 date: Thu Jan 01 00:00:00 1970 +0000
1074 date: Thu Jan 01 00:00:00 1970 +0000
1075 summary: commit on test
1075 summary: commit on test
1076
1076
1077
1077
1078
1078
1079 log -b 2
1079 log -b 2
1080
1080
1081 $ hg log -b 2
1081 $ hg log -b 2
1082 changeset: 2:c3a4f03cc9a7
1082 changeset: 2:c3a4f03cc9a7
1083 parent: 0:24427303d56f
1083 parent: 0:24427303d56f
1084 user: test
1084 user: test
1085 date: Thu Jan 01 00:00:00 1970 +0000
1085 date: Thu Jan 01 00:00:00 1970 +0000
1086 summary: commit on default
1086 summary: commit on default
1087
1087
1088 changeset: 0:24427303d56f
1088 changeset: 0:24427303d56f
1089 user: test
1089 user: test
1090 date: Thu Jan 01 00:00:00 1970 +0000
1090 date: Thu Jan 01 00:00:00 1970 +0000
1091 summary: commit on default
1091 summary: commit on default
1092
1092
1093 #if gettext
1093 #if gettext
1094
1094
1095 Test that all log names are translated (e.g. branches, bookmarks, tags):
1095 Test that all log names are translated (e.g. branches, bookmarks, tags):
1096
1096
1097 $ hg bookmark babar -r tip
1097 $ hg bookmark babar -r tip
1098
1098
1099 $ HGENCODING=UTF-8 LANGUAGE=de hg log -r tip
1099 $ HGENCODING=UTF-8 LANGUAGE=de hg log -r tip
1100 \xc3\x84nderung: 3:f5d8de11c2e2 (esc)
1100 \xc3\x84nderung: 3:f5d8de11c2e2 (esc)
1101 Zweig: test
1101 Zweig: test
1102 Lesezeichen: babar
1102 Lesezeichen: babar
1103 Marke: tip
1103 Marke: tip
1104 Vorg\xc3\xa4nger: 1:d32277701ccb (esc)
1104 Vorg\xc3\xa4nger: 1:d32277701ccb (esc)
1105 Nutzer: test
1105 Nutzer: test
1106 Datum: Thu Jan 01 00:00:00 1970 +0000
1106 Datum: Thu Jan 01 00:00:00 1970 +0000
1107 Zusammenfassung: commit on test
1107 Zusammenfassung: commit on test
1108
1108
1109 $ hg bookmark -d babar
1109 $ hg bookmark -d babar
1110
1110
1111 #endif
1111 #endif
1112
1112
1113 log -p --cwd dir (in subdir)
1113 log -p --cwd dir (in subdir)
1114
1114
1115 $ mkdir dir
1115 $ mkdir dir
1116 $ hg log -p --cwd dir
1116 $ hg log -p --cwd dir
1117 changeset: 3:f5d8de11c2e2
1117 changeset: 3:f5d8de11c2e2
1118 branch: test
1118 branch: test
1119 tag: tip
1119 tag: tip
1120 parent: 1:d32277701ccb
1120 parent: 1:d32277701ccb
1121 user: test
1121 user: test
1122 date: Thu Jan 01 00:00:00 1970 +0000
1122 date: Thu Jan 01 00:00:00 1970 +0000
1123 summary: commit on test
1123 summary: commit on test
1124
1124
1125 diff -r d32277701ccb -r f5d8de11c2e2 c
1125 diff -r d32277701ccb -r f5d8de11c2e2 c
1126 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1126 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1127 +++ b/c Thu Jan 01 00:00:00 1970 +0000
1127 +++ b/c Thu Jan 01 00:00:00 1970 +0000
1128 @@ -0,0 +1,1 @@
1128 @@ -0,0 +1,1 @@
1129 +c
1129 +c
1130
1130
1131 changeset: 2:c3a4f03cc9a7
1131 changeset: 2:c3a4f03cc9a7
1132 parent: 0:24427303d56f
1132 parent: 0:24427303d56f
1133 user: test
1133 user: test
1134 date: Thu Jan 01 00:00:00 1970 +0000
1134 date: Thu Jan 01 00:00:00 1970 +0000
1135 summary: commit on default
1135 summary: commit on default
1136
1136
1137 diff -r 24427303d56f -r c3a4f03cc9a7 c
1137 diff -r 24427303d56f -r c3a4f03cc9a7 c
1138 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1138 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1139 +++ b/c Thu Jan 01 00:00:00 1970 +0000
1139 +++ b/c Thu Jan 01 00:00:00 1970 +0000
1140 @@ -0,0 +1,1 @@
1140 @@ -0,0 +1,1 @@
1141 +c
1141 +c
1142
1142
1143 changeset: 1:d32277701ccb
1143 changeset: 1:d32277701ccb
1144 branch: test
1144 branch: test
1145 user: test
1145 user: test
1146 date: Thu Jan 01 00:00:00 1970 +0000
1146 date: Thu Jan 01 00:00:00 1970 +0000
1147 summary: commit on test
1147 summary: commit on test
1148
1148
1149 diff -r 24427303d56f -r d32277701ccb b
1149 diff -r 24427303d56f -r d32277701ccb b
1150 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1150 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1151 +++ b/b Thu Jan 01 00:00:00 1970 +0000
1151 +++ b/b Thu Jan 01 00:00:00 1970 +0000
1152 @@ -0,0 +1,1 @@
1152 @@ -0,0 +1,1 @@
1153 +b
1153 +b
1154
1154
1155 changeset: 0:24427303d56f
1155 changeset: 0:24427303d56f
1156 user: test
1156 user: test
1157 date: Thu Jan 01 00:00:00 1970 +0000
1157 date: Thu Jan 01 00:00:00 1970 +0000
1158 summary: commit on default
1158 summary: commit on default
1159
1159
1160 diff -r 000000000000 -r 24427303d56f a
1160 diff -r 000000000000 -r 24427303d56f a
1161 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1161 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1162 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1162 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1163 @@ -0,0 +1,1 @@
1163 @@ -0,0 +1,1 @@
1164 +a
1164 +a
1165
1165
1166
1166
1167
1167
1168 log -p -R repo
1168 log -p -R repo
1169
1169
1170 $ cd dir
1170 $ cd dir
1171 $ hg log -p -R .. ../a
1171 $ hg log -p -R .. ../a
1172 changeset: 0:24427303d56f
1172 changeset: 0:24427303d56f
1173 user: test
1173 user: test
1174 date: Thu Jan 01 00:00:00 1970 +0000
1174 date: Thu Jan 01 00:00:00 1970 +0000
1175 summary: commit on default
1175 summary: commit on default
1176
1176
1177 diff -r 000000000000 -r 24427303d56f a
1177 diff -r 000000000000 -r 24427303d56f a
1178 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1178 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1179 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1179 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1180 @@ -0,0 +1,1 @@
1180 @@ -0,0 +1,1 @@
1181 +a
1181 +a
1182
1182
1183
1183
1184 $ cd ../..
1184 $ cd ../..
1185
1185
1186 $ hg init follow2
1186 $ hg init follow2
1187 $ cd follow2
1187 $ cd follow2
1188
1188
1189 # Build the following history:
1189 # Build the following history:
1190 # tip - o - x - o - x - x
1190 # tip - o - x - o - x - x
1191 # \ /
1191 # \ /
1192 # o - o - o - x
1192 # o - o - o - x
1193 # \ /
1193 # \ /
1194 # o
1194 # o
1195 #
1195 #
1196 # Where "o" is a revision containing "foo" and
1196 # Where "o" is a revision containing "foo" and
1197 # "x" is a revision without "foo"
1197 # "x" is a revision without "foo"
1198
1198
1199 $ touch init
1199 $ touch init
1200 $ hg ci -A -m "init, unrelated"
1200 $ hg ci -A -m "init, unrelated"
1201 adding init
1201 adding init
1202 $ echo 'foo' > init
1202 $ echo 'foo' > init
1203 $ hg ci -m "change, unrelated"
1203 $ hg ci -m "change, unrelated"
1204 $ echo 'foo' > foo
1204 $ echo 'foo' > foo
1205 $ hg ci -A -m "add unrelated old foo"
1205 $ hg ci -A -m "add unrelated old foo"
1206 adding foo
1206 adding foo
1207 $ hg rm foo
1207 $ hg rm foo
1208 $ hg ci -m "delete foo, unrelated"
1208 $ hg ci -m "delete foo, unrelated"
1209 $ echo 'related' > foo
1209 $ echo 'related' > foo
1210 $ hg ci -A -m "add foo, related"
1210 $ hg ci -A -m "add foo, related"
1211 adding foo
1211 adding foo
1212
1212
1213 $ hg up 0
1213 $ hg up 0
1214 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
1214 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
1215 $ touch branch
1215 $ touch branch
1216 $ hg ci -A -m "first branch, unrelated"
1216 $ hg ci -A -m "first branch, unrelated"
1217 adding branch
1217 adding branch
1218 created new head
1218 created new head
1219 $ touch foo
1219 $ touch foo
1220 $ hg ci -A -m "create foo, related"
1220 $ hg ci -A -m "create foo, related"
1221 adding foo
1221 adding foo
1222 $ echo 'change' > foo
1222 $ echo 'change' > foo
1223 $ hg ci -m "change foo, related"
1223 $ hg ci -m "change foo, related"
1224
1224
1225 $ hg up 6
1225 $ hg up 6
1226 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1226 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1227 $ echo 'change foo in branch' > foo
1227 $ echo 'change foo in branch' > foo
1228 $ hg ci -m "change foo in branch, related"
1228 $ hg ci -m "change foo in branch, related"
1229 created new head
1229 created new head
1230 $ hg merge 7
1230 $ hg merge 7
1231 merging foo
1231 merging foo
1232 warning: conflicts during merge.
1232 warning: conflicts during merge.
1233 merging foo incomplete! (edit conflicts, then use 'hg resolve --mark')
1233 merging foo incomplete! (edit conflicts, then use 'hg resolve --mark')
1234 0 files updated, 0 files merged, 0 files removed, 1 files unresolved
1234 0 files updated, 0 files merged, 0 files removed, 1 files unresolved
1235 use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
1235 use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
1236 [1]
1236 [1]
1237 $ echo 'merge 1' > foo
1237 $ echo 'merge 1' > foo
1238 $ hg resolve -m foo
1238 $ hg resolve -m foo
1239 (no more unresolved files)
1239 (no more unresolved files)
1240 $ hg ci -m "First merge, related"
1240 $ hg ci -m "First merge, related"
1241
1241
1242 $ hg merge 4
1242 $ hg merge 4
1243 merging foo
1243 merging foo
1244 warning: conflicts during merge.
1244 warning: conflicts during merge.
1245 merging foo incomplete! (edit conflicts, then use 'hg resolve --mark')
1245 merging foo incomplete! (edit conflicts, then use 'hg resolve --mark')
1246 1 files updated, 0 files merged, 0 files removed, 1 files unresolved
1246 1 files updated, 0 files merged, 0 files removed, 1 files unresolved
1247 use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
1247 use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
1248 [1]
1248 [1]
1249 $ echo 'merge 2' > foo
1249 $ echo 'merge 2' > foo
1250 $ hg resolve -m foo
1250 $ hg resolve -m foo
1251 (no more unresolved files)
1251 (no more unresolved files)
1252 $ hg ci -m "Last merge, related"
1252 $ hg ci -m "Last merge, related"
1253
1253
1254 $ hg log --graph
1254 $ hg log --graph
1255 @ changeset: 10:4dae8563d2c5
1255 @ changeset: 10:4dae8563d2c5
1256 |\ tag: tip
1256 |\ tag: tip
1257 | | parent: 9:7b35701b003e
1257 | | parent: 9:7b35701b003e
1258 | | parent: 4:88176d361b69
1258 | | parent: 4:88176d361b69
1259 | | user: test
1259 | | user: test
1260 | | date: Thu Jan 01 00:00:00 1970 +0000
1260 | | date: Thu Jan 01 00:00:00 1970 +0000
1261 | | summary: Last merge, related
1261 | | summary: Last merge, related
1262 | |
1262 | |
1263 | o changeset: 9:7b35701b003e
1263 | o changeset: 9:7b35701b003e
1264 | |\ parent: 8:e5416ad8a855
1264 | |\ parent: 8:e5416ad8a855
1265 | | | parent: 7:87fe3144dcfa
1265 | | | parent: 7:87fe3144dcfa
1266 | | | user: test
1266 | | | user: test
1267 | | | date: Thu Jan 01 00:00:00 1970 +0000
1267 | | | date: Thu Jan 01 00:00:00 1970 +0000
1268 | | | summary: First merge, related
1268 | | | summary: First merge, related
1269 | | |
1269 | | |
1270 | | o changeset: 8:e5416ad8a855
1270 | | o changeset: 8:e5416ad8a855
1271 | | | parent: 6:dc6c325fe5ee
1271 | | | parent: 6:dc6c325fe5ee
1272 | | | user: test
1272 | | | user: test
1273 | | | date: Thu Jan 01 00:00:00 1970 +0000
1273 | | | date: Thu Jan 01 00:00:00 1970 +0000
1274 | | | summary: change foo in branch, related
1274 | | | summary: change foo in branch, related
1275 | | |
1275 | | |
1276 | o | changeset: 7:87fe3144dcfa
1276 | o | changeset: 7:87fe3144dcfa
1277 | |/ user: test
1277 | |/ user: test
1278 | | date: Thu Jan 01 00:00:00 1970 +0000
1278 | | date: Thu Jan 01 00:00:00 1970 +0000
1279 | | summary: change foo, related
1279 | | summary: change foo, related
1280 | |
1280 | |
1281 | o changeset: 6:dc6c325fe5ee
1281 | o changeset: 6:dc6c325fe5ee
1282 | | user: test
1282 | | user: test
1283 | | date: Thu Jan 01 00:00:00 1970 +0000
1283 | | date: Thu Jan 01 00:00:00 1970 +0000
1284 | | summary: create foo, related
1284 | | summary: create foo, related
1285 | |
1285 | |
1286 | o changeset: 5:73db34516eb9
1286 | o changeset: 5:73db34516eb9
1287 | | parent: 0:e87515fd044a
1287 | | parent: 0:e87515fd044a
1288 | | user: test
1288 | | user: test
1289 | | date: Thu Jan 01 00:00:00 1970 +0000
1289 | | date: Thu Jan 01 00:00:00 1970 +0000
1290 | | summary: first branch, unrelated
1290 | | summary: first branch, unrelated
1291 | |
1291 | |
1292 o | changeset: 4:88176d361b69
1292 o | changeset: 4:88176d361b69
1293 | | user: test
1293 | | user: test
1294 | | date: Thu Jan 01 00:00:00 1970 +0000
1294 | | date: Thu Jan 01 00:00:00 1970 +0000
1295 | | summary: add foo, related
1295 | | summary: add foo, related
1296 | |
1296 | |
1297 o | changeset: 3:dd78ae4afb56
1297 o | changeset: 3:dd78ae4afb56
1298 | | user: test
1298 | | user: test
1299 | | date: Thu Jan 01 00:00:00 1970 +0000
1299 | | date: Thu Jan 01 00:00:00 1970 +0000
1300 | | summary: delete foo, unrelated
1300 | | summary: delete foo, unrelated
1301 | |
1301 | |
1302 o | changeset: 2:c4c64aedf0f7
1302 o | changeset: 2:c4c64aedf0f7
1303 | | user: test
1303 | | user: test
1304 | | date: Thu Jan 01 00:00:00 1970 +0000
1304 | | date: Thu Jan 01 00:00:00 1970 +0000
1305 | | summary: add unrelated old foo
1305 | | summary: add unrelated old foo
1306 | |
1306 | |
1307 o | changeset: 1:e5faa7440653
1307 o | changeset: 1:e5faa7440653
1308 |/ user: test
1308 |/ user: test
1309 | date: Thu Jan 01 00:00:00 1970 +0000
1309 | date: Thu Jan 01 00:00:00 1970 +0000
1310 | summary: change, unrelated
1310 | summary: change, unrelated
1311 |
1311 |
1312 o changeset: 0:e87515fd044a
1312 o changeset: 0:e87515fd044a
1313 user: test
1313 user: test
1314 date: Thu Jan 01 00:00:00 1970 +0000
1314 date: Thu Jan 01 00:00:00 1970 +0000
1315 summary: init, unrelated
1315 summary: init, unrelated
1316
1316
1317
1317
1318 $ hg --traceback log -f foo
1318 $ hg --traceback log -f foo
1319 changeset: 10:4dae8563d2c5
1319 changeset: 10:4dae8563d2c5
1320 tag: tip
1320 tag: tip
1321 parent: 9:7b35701b003e
1321 parent: 9:7b35701b003e
1322 parent: 4:88176d361b69
1322 parent: 4:88176d361b69
1323 user: test
1323 user: test
1324 date: Thu Jan 01 00:00:00 1970 +0000
1324 date: Thu Jan 01 00:00:00 1970 +0000
1325 summary: Last merge, related
1325 summary: Last merge, related
1326
1326
1327 changeset: 9:7b35701b003e
1327 changeset: 9:7b35701b003e
1328 parent: 8:e5416ad8a855
1328 parent: 8:e5416ad8a855
1329 parent: 7:87fe3144dcfa
1329 parent: 7:87fe3144dcfa
1330 user: test
1330 user: test
1331 date: Thu Jan 01 00:00:00 1970 +0000
1331 date: Thu Jan 01 00:00:00 1970 +0000
1332 summary: First merge, related
1332 summary: First merge, related
1333
1333
1334 changeset: 8:e5416ad8a855
1334 changeset: 8:e5416ad8a855
1335 parent: 6:dc6c325fe5ee
1335 parent: 6:dc6c325fe5ee
1336 user: test
1336 user: test
1337 date: Thu Jan 01 00:00:00 1970 +0000
1337 date: Thu Jan 01 00:00:00 1970 +0000
1338 summary: change foo in branch, related
1338 summary: change foo in branch, related
1339
1339
1340 changeset: 7:87fe3144dcfa
1340 changeset: 7:87fe3144dcfa
1341 user: test
1341 user: test
1342 date: Thu Jan 01 00:00:00 1970 +0000
1342 date: Thu Jan 01 00:00:00 1970 +0000
1343 summary: change foo, related
1343 summary: change foo, related
1344
1344
1345 changeset: 6:dc6c325fe5ee
1345 changeset: 6:dc6c325fe5ee
1346 user: test
1346 user: test
1347 date: Thu Jan 01 00:00:00 1970 +0000
1347 date: Thu Jan 01 00:00:00 1970 +0000
1348 summary: create foo, related
1348 summary: create foo, related
1349
1349
1350 changeset: 4:88176d361b69
1350 changeset: 4:88176d361b69
1351 user: test
1351 user: test
1352 date: Thu Jan 01 00:00:00 1970 +0000
1352 date: Thu Jan 01 00:00:00 1970 +0000
1353 summary: add foo, related
1353 summary: add foo, related
1354
1354
1355
1355
1356 Also check when maxrev < lastrevfilelog
1356 Also check when maxrev < lastrevfilelog
1357
1357
1358 $ hg --traceback log -f -r4 foo
1358 $ hg --traceback log -f -r4 foo
1359 changeset: 4:88176d361b69
1359 changeset: 4:88176d361b69
1360 user: test
1360 user: test
1361 date: Thu Jan 01 00:00:00 1970 +0000
1361 date: Thu Jan 01 00:00:00 1970 +0000
1362 summary: add foo, related
1362 summary: add foo, related
1363
1363
1364 changeset: 2:c4c64aedf0f7
1364 changeset: 2:c4c64aedf0f7
1365 user: test
1365 user: test
1366 date: Thu Jan 01 00:00:00 1970 +0000
1366 date: Thu Jan 01 00:00:00 1970 +0000
1367 summary: add unrelated old foo
1367 summary: add unrelated old foo
1368
1368
1369 $ cd ..
1369 $ cd ..
1370
1370
1371 Issue2383: hg log showing _less_ differences than hg diff
1371 Issue2383: hg log showing _less_ differences than hg diff
1372
1372
1373 $ hg init issue2383
1373 $ hg init issue2383
1374 $ cd issue2383
1374 $ cd issue2383
1375
1375
1376 Create a test repo:
1376 Create a test repo:
1377
1377
1378 $ echo a > a
1378 $ echo a > a
1379 $ hg ci -Am0
1379 $ hg ci -Am0
1380 adding a
1380 adding a
1381 $ echo b > b
1381 $ echo b > b
1382 $ hg ci -Am1
1382 $ hg ci -Am1
1383 adding b
1383 adding b
1384 $ hg co 0
1384 $ hg co 0
1385 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1385 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1386 $ echo b > a
1386 $ echo b > a
1387 $ hg ci -m2
1387 $ hg ci -m2
1388 created new head
1388 created new head
1389
1389
1390 Merge:
1390 Merge:
1391
1391
1392 $ hg merge
1392 $ hg merge
1393 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1393 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1394 (branch merge, don't forget to commit)
1394 (branch merge, don't forget to commit)
1395
1395
1396 Make sure there's a file listed in the merge to trigger the bug:
1396 Make sure there's a file listed in the merge to trigger the bug:
1397
1397
1398 $ echo c > a
1398 $ echo c > a
1399 $ hg ci -m3
1399 $ hg ci -m3
1400
1400
1401 Two files shown here in diff:
1401 Two files shown here in diff:
1402
1402
1403 $ hg diff --rev 2:3
1403 $ hg diff --rev 2:3
1404 diff -r b09be438c43a -r 8e07aafe1edc a
1404 diff -r b09be438c43a -r 8e07aafe1edc a
1405 --- a/a Thu Jan 01 00:00:00 1970 +0000
1405 --- a/a Thu Jan 01 00:00:00 1970 +0000
1406 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1406 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1407 @@ -1,1 +1,1 @@
1407 @@ -1,1 +1,1 @@
1408 -b
1408 -b
1409 +c
1409 +c
1410 diff -r b09be438c43a -r 8e07aafe1edc b
1410 diff -r b09be438c43a -r 8e07aafe1edc b
1411 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1411 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1412 +++ b/b Thu Jan 01 00:00:00 1970 +0000
1412 +++ b/b Thu Jan 01 00:00:00 1970 +0000
1413 @@ -0,0 +1,1 @@
1413 @@ -0,0 +1,1 @@
1414 +b
1414 +b
1415
1415
1416 Diff here should be the same:
1416 Diff here should be the same:
1417
1417
1418 $ hg log -vpr 3
1418 $ hg log -vpr 3
1419 changeset: 3:8e07aafe1edc
1419 changeset: 3:8e07aafe1edc
1420 tag: tip
1420 tag: tip
1421 parent: 2:b09be438c43a
1421 parent: 2:b09be438c43a
1422 parent: 1:925d80f479bb
1422 parent: 1:925d80f479bb
1423 user: test
1423 user: test
1424 date: Thu Jan 01 00:00:00 1970 +0000
1424 date: Thu Jan 01 00:00:00 1970 +0000
1425 files: a
1425 files: a
1426 description:
1426 description:
1427 3
1427 3
1428
1428
1429
1429
1430 diff -r b09be438c43a -r 8e07aafe1edc a
1430 diff -r b09be438c43a -r 8e07aafe1edc a
1431 --- a/a Thu Jan 01 00:00:00 1970 +0000
1431 --- a/a Thu Jan 01 00:00:00 1970 +0000
1432 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1432 +++ b/a Thu Jan 01 00:00:00 1970 +0000
1433 @@ -1,1 +1,1 @@
1433 @@ -1,1 +1,1 @@
1434 -b
1434 -b
1435 +c
1435 +c
1436 diff -r b09be438c43a -r 8e07aafe1edc b
1436 diff -r b09be438c43a -r 8e07aafe1edc b
1437 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1437 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1438 +++ b/b Thu Jan 01 00:00:00 1970 +0000
1438 +++ b/b Thu Jan 01 00:00:00 1970 +0000
1439 @@ -0,0 +1,1 @@
1439 @@ -0,0 +1,1 @@
1440 +b
1440 +b
1441
1441
1442 $ cd ..
1442 $ cd ..
1443
1443
1444 'hg log -r rev fn' when last(filelog(fn)) != rev
1444 'hg log -r rev fn' when last(filelog(fn)) != rev
1445
1445
1446 $ hg init simplelog
1446 $ hg init simplelog
1447 $ cd simplelog
1447 $ cd simplelog
1448 $ echo f > a
1448 $ echo f > a
1449 $ hg ci -Am'a' -d '0 0'
1449 $ hg ci -Am'a' -d '0 0'
1450 adding a
1450 adding a
1451 $ echo f >> a
1451 $ echo f >> a
1452 $ hg ci -Am'a bis' -d '1 0'
1452 $ hg ci -Am'a bis' -d '1 0'
1453
1453
1454 $ hg log -r0 a
1454 $ hg log -r0 a
1455 changeset: 0:9f758d63dcde
1455 changeset: 0:9f758d63dcde
1456 user: test
1456 user: test
1457 date: Thu Jan 01 00:00:00 1970 +0000
1457 date: Thu Jan 01 00:00:00 1970 +0000
1458 summary: a
1458 summary: a
1459
1459
1460 enable obsolete to test hidden feature
1460 enable obsolete to test hidden feature
1461
1461
1462 $ cat >> $HGRCPATH << EOF
1462 $ cat >> $HGRCPATH << EOF
1463 > [experimental]
1463 > [experimental]
1464 > evolution=createmarkers
1464 > evolution=createmarkers
1465 > EOF
1465 > EOF
1466
1466
1467 $ hg log --template='{rev}:{node}\n'
1467 $ hg log --template='{rev}:{node}\n'
1468 1:a765632148dc55d38c35c4f247c618701886cb2f
1468 1:a765632148dc55d38c35c4f247c618701886cb2f
1469 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1469 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1470 $ hg debugobsolete a765632148dc55d38c35c4f247c618701886cb2f
1470 $ hg debugobsolete a765632148dc55d38c35c4f247c618701886cb2f
1471 $ hg up null -q
1471 $ hg up null -q
1472 $ hg log --template='{rev}:{node}\n'
1472 $ hg log --template='{rev}:{node}\n'
1473 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1473 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1474 $ hg log --template='{rev}:{node}\n' --hidden
1474 $ hg log --template='{rev}:{node}\n' --hidden
1475 1:a765632148dc55d38c35c4f247c618701886cb2f
1475 1:a765632148dc55d38c35c4f247c618701886cb2f
1476 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1476 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1477 $ hg log -r a
1477 $ hg log -r a
1478 abort: hidden revision 'a'!
1478 abort: hidden revision 'a'!
1479 (use --hidden to access hidden revisions)
1479 (use --hidden to access hidden revisions)
1480 [255]
1480 [255]
1481
1481
1482 test that parent prevent a changeset to be hidden
1482 test that parent prevent a changeset to be hidden
1483
1483
1484 $ hg up 1 -q --hidden
1484 $ hg up 1 -q --hidden
1485 $ hg log --template='{rev}:{node}\n'
1485 $ hg log --template='{rev}:{node}\n'
1486 1:a765632148dc55d38c35c4f247c618701886cb2f
1486 1:a765632148dc55d38c35c4f247c618701886cb2f
1487 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1487 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1488
1488
1489 test that second parent prevent a changeset to be hidden too
1489 test that second parent prevent a changeset to be hidden too
1490
1490
1491 $ hg debugsetparents 0 1 # nothing suitable to merge here
1491 $ hg debugsetparents 0 1 # nothing suitable to merge here
1492 $ hg log --template='{rev}:{node}\n'
1492 $ hg log --template='{rev}:{node}\n'
1493 1:a765632148dc55d38c35c4f247c618701886cb2f
1493 1:a765632148dc55d38c35c4f247c618701886cb2f
1494 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1494 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1495 $ hg debugsetparents 1
1495 $ hg debugsetparents 1
1496 $ hg up -q null
1496 $ hg up -q null
1497
1497
1498 bookmarks prevent a changeset being hidden
1498 bookmarks prevent a changeset being hidden
1499
1499
1500 $ hg bookmark --hidden -r 1 X
1500 $ hg bookmark --hidden -r 1 X
1501 $ hg log --template '{rev}:{node}\n'
1501 $ hg log --template '{rev}:{node}\n'
1502 1:a765632148dc55d38c35c4f247c618701886cb2f
1502 1:a765632148dc55d38c35c4f247c618701886cb2f
1503 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1503 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1504 $ hg bookmark -d X
1504 $ hg bookmark -d X
1505
1505
1506 divergent bookmarks are not hidden
1506 divergent bookmarks are not hidden
1507
1507
1508 $ hg bookmark --hidden -r 1 X@foo
1508 $ hg bookmark --hidden -r 1 X@foo
1509 $ hg log --template '{rev}:{node}\n'
1509 $ hg log --template '{rev}:{node}\n'
1510 1:a765632148dc55d38c35c4f247c618701886cb2f
1510 1:a765632148dc55d38c35c4f247c618701886cb2f
1511 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1511 0:9f758d63dcde62d547ebfb08e1e7ee96535f2b05
1512
1512
1513 clear extensions configuration
1513 clear extensions configuration
1514 $ echo '[extensions]' >> $HGRCPATH
1514 $ echo '[extensions]' >> $HGRCPATH
1515 $ echo "obs=!" >> $HGRCPATH
1515 $ echo "obs=!" >> $HGRCPATH
1516 $ cd ..
1516 $ cd ..
1517
1517
1518 test -u/-k for problematic encoding
1518 test -u/-k for problematic encoding
1519 # unicode: cp932:
1519 # unicode: cp932:
1520 # u30A2 0x83 0x41(= 'A')
1520 # u30A2 0x83 0x41(= 'A')
1521 # u30C2 0x83 0x61(= 'a')
1521 # u30C2 0x83 0x61(= 'a')
1522
1522
1523 $ hg init problematicencoding
1523 $ hg init problematicencoding
1524 $ cd problematicencoding
1524 $ cd problematicencoding
1525
1525
1526 $ python > setup.sh <<EOF
1526 $ python > setup.sh <<EOF
1527 > print u'''
1527 > print u'''
1528 > echo a > text
1528 > echo a > text
1529 > hg add text
1529 > hg add text
1530 > hg --encoding utf-8 commit -u '\u30A2' -m none
1530 > hg --encoding utf-8 commit -u '\u30A2' -m none
1531 > echo b > text
1531 > echo b > text
1532 > hg --encoding utf-8 commit -u '\u30C2' -m none
1532 > hg --encoding utf-8 commit -u '\u30C2' -m none
1533 > echo c > text
1533 > echo c > text
1534 > hg --encoding utf-8 commit -u none -m '\u30A2'
1534 > hg --encoding utf-8 commit -u none -m '\u30A2'
1535 > echo d > text
1535 > echo d > text
1536 > hg --encoding utf-8 commit -u none -m '\u30C2'
1536 > hg --encoding utf-8 commit -u none -m '\u30C2'
1537 > '''.encode('utf-8')
1537 > '''.encode('utf-8')
1538 > EOF
1538 > EOF
1539 $ sh < setup.sh
1539 $ sh < setup.sh
1540
1540
1541 test in problematic encoding
1541 test in problematic encoding
1542 $ python > test.sh <<EOF
1542 $ python > test.sh <<EOF
1543 > print u'''
1543 > print u'''
1544 > hg --encoding cp932 log --template '{rev}\\n' -u '\u30A2'
1544 > hg --encoding cp932 log --template '{rev}\\n' -u '\u30A2'
1545 > echo ====
1545 > echo ====
1546 > hg --encoding cp932 log --template '{rev}\\n' -u '\u30C2'
1546 > hg --encoding cp932 log --template '{rev}\\n' -u '\u30C2'
1547 > echo ====
1547 > echo ====
1548 > hg --encoding cp932 log --template '{rev}\\n' -k '\u30A2'
1548 > hg --encoding cp932 log --template '{rev}\\n' -k '\u30A2'
1549 > echo ====
1549 > echo ====
1550 > hg --encoding cp932 log --template '{rev}\\n' -k '\u30C2'
1550 > hg --encoding cp932 log --template '{rev}\\n' -k '\u30C2'
1551 > '''.encode('cp932')
1551 > '''.encode('cp932')
1552 > EOF
1552 > EOF
1553 $ sh < test.sh
1553 $ sh < test.sh
1554 0
1554 0
1555 ====
1555 ====
1556 1
1556 1
1557 ====
1557 ====
1558 2
1558 2
1559 0
1559 0
1560 ====
1560 ====
1561 3
1561 3
1562 1
1562 1
1563
1563
1564 $ cd ..
1564 $ cd ..
1565
1565
1566 test hg log on non-existent files and on directories
1566 test hg log on non-existent files and on directories
1567 $ hg init issue1340
1567 $ hg init issue1340
1568 $ cd issue1340
1568 $ cd issue1340
1569 $ mkdir d1; mkdir D2; mkdir D3.i; mkdir d4.hg; mkdir d5.d; mkdir .d6
1569 $ mkdir d1; mkdir D2; mkdir D3.i; mkdir d4.hg; mkdir d5.d; mkdir .d6
1570 $ echo 1 > d1/f1
1570 $ echo 1 > d1/f1
1571 $ echo 1 > D2/f1
1571 $ echo 1 > D2/f1
1572 $ echo 1 > D3.i/f1
1572 $ echo 1 > D3.i/f1
1573 $ echo 1 > d4.hg/f1
1573 $ echo 1 > d4.hg/f1
1574 $ echo 1 > d5.d/f1
1574 $ echo 1 > d5.d/f1
1575 $ echo 1 > .d6/f1
1575 $ echo 1 > .d6/f1
1576 $ hg -q add .
1576 $ hg -q add .
1577 $ hg commit -m "a bunch of weird directories"
1577 $ hg commit -m "a bunch of weird directories"
1578 $ hg log -l1 d1/f1 | grep changeset
1578 $ hg log -l1 d1/f1 | grep changeset
1579 changeset: 0:65624cd9070a
1579 changeset: 0:65624cd9070a
1580 $ hg log -l1 f1
1580 $ hg log -l1 f1
1581 $ hg log -l1 . | grep changeset
1581 $ hg log -l1 . | grep changeset
1582 changeset: 0:65624cd9070a
1582 changeset: 0:65624cd9070a
1583 $ hg log -l1 ./ | grep changeset
1583 $ hg log -l1 ./ | grep changeset
1584 changeset: 0:65624cd9070a
1584 changeset: 0:65624cd9070a
1585 $ hg log -l1 d1 | grep changeset
1585 $ hg log -l1 d1 | grep changeset
1586 changeset: 0:65624cd9070a
1586 changeset: 0:65624cd9070a
1587 $ hg log -l1 D2 | grep changeset
1587 $ hg log -l1 D2 | grep changeset
1588 changeset: 0:65624cd9070a
1588 changeset: 0:65624cd9070a
1589 $ hg log -l1 D2/f1 | grep changeset
1589 $ hg log -l1 D2/f1 | grep changeset
1590 changeset: 0:65624cd9070a
1590 changeset: 0:65624cd9070a
1591 $ hg log -l1 D3.i | grep changeset
1591 $ hg log -l1 D3.i | grep changeset
1592 changeset: 0:65624cd9070a
1592 changeset: 0:65624cd9070a
1593 $ hg log -l1 D3.i/f1 | grep changeset
1593 $ hg log -l1 D3.i/f1 | grep changeset
1594 changeset: 0:65624cd9070a
1594 changeset: 0:65624cd9070a
1595 $ hg log -l1 d4.hg | grep changeset
1595 $ hg log -l1 d4.hg | grep changeset
1596 changeset: 0:65624cd9070a
1596 changeset: 0:65624cd9070a
1597 $ hg log -l1 d4.hg/f1 | grep changeset
1597 $ hg log -l1 d4.hg/f1 | grep changeset
1598 changeset: 0:65624cd9070a
1598 changeset: 0:65624cd9070a
1599 $ hg log -l1 d5.d | grep changeset
1599 $ hg log -l1 d5.d | grep changeset
1600 changeset: 0:65624cd9070a
1600 changeset: 0:65624cd9070a
1601 $ hg log -l1 d5.d/f1 | grep changeset
1601 $ hg log -l1 d5.d/f1 | grep changeset
1602 changeset: 0:65624cd9070a
1602 changeset: 0:65624cd9070a
1603 $ hg log -l1 .d6 | grep changeset
1603 $ hg log -l1 .d6 | grep changeset
1604 changeset: 0:65624cd9070a
1604 changeset: 0:65624cd9070a
1605 $ hg log -l1 .d6/f1 | grep changeset
1605 $ hg log -l1 .d6/f1 | grep changeset
1606 changeset: 0:65624cd9070a
1606 changeset: 0:65624cd9070a
1607
1607
1608 issue3772: hg log -r :null showing revision 0 as well
1608 issue3772: hg log -r :null showing revision 0 as well
1609
1609
1610 $ hg log -r :null
1610 $ hg log -r :null
1611 changeset: 0:65624cd9070a
1611 changeset: 0:65624cd9070a
1612 tag: tip
1612 tag: tip
1613 user: test
1613 user: test
1614 date: Thu Jan 01 00:00:00 1970 +0000
1614 date: Thu Jan 01 00:00:00 1970 +0000
1615 summary: a bunch of weird directories
1615 summary: a bunch of weird directories
1616
1616
1617 changeset: -1:000000000000
1617 changeset: -1:000000000000
1618 user:
1618 user:
1619 date: Thu Jan 01 00:00:00 1970 +0000
1619 date: Thu Jan 01 00:00:00 1970 +0000
1620
1620
1621 $ hg log -r null:null
1621 $ hg log -r null:null
1622 changeset: -1:000000000000
1622 changeset: -1:000000000000
1623 user:
1623 user:
1624 date: Thu Jan 01 00:00:00 1970 +0000
1624 date: Thu Jan 01 00:00:00 1970 +0000
1625
1625
1626 working-directory revision requires special treatment
1626 working-directory revision requires special treatment
1627
1627
1628 $ hg log -r 'wdir()'
1628 $ hg log -r 'wdir()'
1629 changeset: 0:65624cd9070a+
1629 changeset: 0:65624cd9070a+
1630 user: test
1630 user: test
1631 date: [A-Za-z0-9:+ ]+ (re)
1631 date: [A-Za-z0-9:+ ]+ (re)
1632
1632
1633 $ hg log -r 'wdir()' -q
1633 $ hg log -r 'wdir()' -q
1634 0:65624cd9070a+
1634 0:65624cd9070a+
1635
1635
1636 $ hg log -r 'wdir()' --debug
1636 $ hg log -r 'wdir()' --debug
1637 changeset: 0:65624cd9070a035fa7191a54f2b8af39f16b0c08+
1637 changeset: 0:65624cd9070a035fa7191a54f2b8af39f16b0c08+
1638 phase: draft
1638 phase: draft
1639 parent: 0:65624cd9070a035fa7191a54f2b8af39f16b0c08
1639 parent: 0:65624cd9070a035fa7191a54f2b8af39f16b0c08
1640 parent: -1:0000000000000000000000000000000000000000
1640 parent: -1:0000000000000000000000000000000000000000
1641 user: test
1641 user: test
1642 date: [A-Za-z0-9:+ ]+ (re)
1642 date: [A-Za-z0-9:+ ]+ (re)
1643 extra: branch=default
1643 extra: branch=default
1644
1644
1645 $ hg log -r 'wdir()' -Tjson
1645 $ hg log -r 'wdir()' -Tjson
1646 [
1646 [
1647 {
1647 {
1648 "rev": null,
1648 "rev": null,
1649 "node": null,
1649 "node": null,
1650 "branch": "default",
1650 "branch": "default",
1651 "phase": "draft",
1651 "phase": "draft",
1652 "user": "test",
1652 "user": "test",
1653 "date": [*, 0], (glob)
1653 "date": [*, 0], (glob)
1654 "desc": "",
1654 "desc": "",
1655 "bookmarks": [],
1655 "bookmarks": [],
1656 "tags": ["tip"],
1656 "tags": ["tip"],
1657 "parents": ["65624cd9070a035fa7191a54f2b8af39f16b0c08"]
1657 "parents": ["65624cd9070a035fa7191a54f2b8af39f16b0c08"]
1658 }
1658 }
1659 ]
1659 ]
1660
1660
1661 $ hg log -r 'wdir()' -Tjson -q
1661 $ hg log -r 'wdir()' -Tjson -q
1662 [
1662 [
1663 {
1663 {
1664 "rev": null,
1664 "rev": null,
1665 "node": null
1665 "node": null
1666 }
1666 }
1667 ]
1667 ]
1668
1668
1669 $ hg log -r 'wdir()' -Tjson --debug
1669 $ hg log -r 'wdir()' -Tjson --debug
1670 [
1670 [
1671 {
1671 {
1672 "rev": null,
1672 "rev": null,
1673 "node": null,
1673 "node": null,
1674 "branch": "default",
1674 "branch": "default",
1675 "phase": "draft",
1675 "phase": "draft",
1676 "user": "test",
1676 "user": "test",
1677 "date": [*, 0], (glob)
1677 "date": [*, 0], (glob)
1678 "desc": "",
1678 "desc": "",
1679 "bookmarks": [],
1679 "bookmarks": [],
1680 "tags": ["tip"],
1680 "tags": ["tip"],
1681 "parents": ["65624cd9070a035fa7191a54f2b8af39f16b0c08"],
1681 "parents": ["65624cd9070a035fa7191a54f2b8af39f16b0c08"],
1682 "manifest": null,
1682 "manifest": null,
1683 "extra": {"branch": "default"},
1683 "extra": {"branch": "default"},
1684 "modified": [],
1684 "modified": [],
1685 "added": [],
1685 "added": [],
1686 "removed": []
1686 "removed": []
1687 }
1687 }
1688 ]
1688 ]
1689
1689
1690 Check that adding an arbitrary name shows up in log automatically
1690 Check that adding an arbitrary name shows up in log automatically
1691
1691
1692 $ cat > ../names.py <<EOF
1692 $ cat > ../names.py <<EOF
1693 > """A small extension to test adding arbitrary names to a repo"""
1693 > """A small extension to test adding arbitrary names to a repo"""
1694 > from mercurial.namespaces import namespace
1694 > from mercurial.namespaces import namespace
1695 >
1695 >
1696 > def reposetup(ui, repo):
1696 > def reposetup(ui, repo):
1697 > foo = {'foo': repo[0].node()}
1697 > foo = {'foo': repo[0].node()}
1698 > names = lambda r: foo.keys()
1698 > names = lambda r: foo.keys()
1699 > namemap = lambda r, name: foo.get(name)
1699 > namemap = lambda r, name: foo.get(name)
1700 > nodemap = lambda r, node: [name for name, n in foo.iteritems()
1700 > nodemap = lambda r, node: [name for name, n in foo.iteritems()
1701 > if n == node]
1701 > if n == node]
1702 > ns = namespace("bars", templatename="bar", logname="barlog",
1702 > ns = namespace("bars", templatename="bar", logname="barlog",
1703 > colorname="barcolor", listnames=names, namemap=namemap,
1703 > colorname="barcolor", listnames=names, namemap=namemap,
1704 > nodemap=nodemap)
1704 > nodemap=nodemap)
1705 >
1705 >
1706 > repo.names.addnamespace(ns)
1706 > repo.names.addnamespace(ns)
1707 > EOF
1707 > EOF
1708
1708
1709 $ hg --config extensions.names=../names.py log -r 0
1709 $ hg --config extensions.names=../names.py log -r 0
1710 changeset: 0:65624cd9070a
1710 changeset: 0:65624cd9070a
1711 tag: tip
1711 tag: tip
1712 barlog: foo
1712 barlog: foo
1713 user: test
1713 user: test
1714 date: Thu Jan 01 00:00:00 1970 +0000
1714 date: Thu Jan 01 00:00:00 1970 +0000
1715 summary: a bunch of weird directories
1715 summary: a bunch of weird directories
1716
1716
1717 $ hg --config extensions.names=../names.py \
1717 $ hg --config extensions.names=../names.py \
1718 > --config extensions.color= --config color.log.barcolor=red \
1718 > --config extensions.color= --config color.log.barcolor=red \
1719 > --color=always log -r 0
1719 > --color=always log -r 0
1720 \x1b[0;33mchangeset: 0:65624cd9070a\x1b[0m (esc)
1720 \x1b[0;33mchangeset: 0:65624cd9070a\x1b[0m (esc)
1721 tag: tip
1721 tag: tip
1722 \x1b[0;31mbarlog: foo\x1b[0m (esc)
1722 \x1b[0;31mbarlog: foo\x1b[0m (esc)
1723 user: test
1723 user: test
1724 date: Thu Jan 01 00:00:00 1970 +0000
1724 date: Thu Jan 01 00:00:00 1970 +0000
1725 summary: a bunch of weird directories
1725 summary: a bunch of weird directories
1726
1726
1727 $ hg --config extensions.names=../names.py log -r 0 --template '{bars}\n'
1727 $ hg --config extensions.names=../names.py log -r 0 --template '{bars}\n'
1728 foo
1728 foo
1729
1729
1730 $ cd ..
1730 $ cd ..
1731
1731
1732 hg log -f dir across branches
1732 hg log -f dir across branches
1733
1733
1734 $ hg init acrossbranches
1734 $ hg init acrossbranches
1735 $ cd acrossbranches
1735 $ cd acrossbranches
1736 $ mkdir d
1736 $ mkdir d
1737 $ echo a > d/a && hg ci -Aqm a
1737 $ echo a > d/a && hg ci -Aqm a
1738 $ echo b > d/a && hg ci -Aqm b
1738 $ echo b > d/a && hg ci -Aqm b
1739 $ hg up -q 0
1739 $ hg up -q 0
1740 $ echo b > d/a && hg ci -Aqm c
1740 $ echo b > d/a && hg ci -Aqm c
1741 $ hg log -f d -T '{desc}' -G
1741 $ hg log -f d -T '{desc}' -G
1742 @ c
1742 @ c
1743 |
1743 |
1744 o a
1744 o a
1745
1745
1746 Ensure that largefiles doesn't interfere with following a normal file
1746 Ensure that largefiles doesn't interfere with following a normal file
1747 $ hg --config extensions.largefiles= log -f d -T '{desc}' -G
1747 $ hg --config extensions.largefiles= log -f d -T '{desc}' -G
1748 @ c
1748 @ c
1749 |
1749 |
1750 o a
1750 o a
1751
1751
1752 $ hg log -f d/a -T '{desc}' -G
1752 $ hg log -f d/a -T '{desc}' -G
1753 @ c
1753 @ c
1754 |
1754 |
1755 o a
1755 o a
1756
1756
1757 $ cd ..
1757 $ cd ..
1758
1758
1759 hg log -f with linkrev pointing to another branch
1759 hg log -f with linkrev pointing to another branch
1760 -------------------------------------------------
1760 -------------------------------------------------
1761
1761
1762 create history with a filerev whose linkrev points to another branch
1762 create history with a filerev whose linkrev points to another branch
1763
1763
1764 $ hg init branchedlinkrev
1764 $ hg init branchedlinkrev
1765 $ cd branchedlinkrev
1765 $ cd branchedlinkrev
1766 $ echo 1 > a
1766 $ echo 1 > a
1767 $ hg commit -Am 'content1'
1767 $ hg commit -Am 'content1'
1768 adding a
1768 adding a
1769 $ echo 2 > a
1769 $ echo 2 > a
1770 $ hg commit -m 'content2'
1770 $ hg commit -m 'content2'
1771 $ hg up --rev 'desc(content1)'
1771 $ hg up --rev 'desc(content1)'
1772 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1772 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1773 $ echo unrelated > unrelated
1773 $ echo unrelated > unrelated
1774 $ hg commit -Am 'unrelated'
1774 $ hg commit -Am 'unrelated'
1775 adding unrelated
1775 adding unrelated
1776 created new head
1776 created new head
1777 $ hg graft -r 'desc(content2)'
1777 $ hg graft -r 'desc(content2)'
1778 grafting 1:2294ae80ad84 "content2"
1778 grafting 1:2294ae80ad84 "content2"
1779 $ echo 3 > a
1779 $ echo 3 > a
1780 $ hg commit -m 'content3'
1780 $ hg commit -m 'content3'
1781 $ hg log -G
1781 $ hg log -G
1782 @ changeset: 4:50b9b36e9c5d
1782 @ changeset: 4:50b9b36e9c5d
1783 | tag: tip
1783 | tag: tip
1784 | user: test
1784 | user: test
1785 | date: Thu Jan 01 00:00:00 1970 +0000
1785 | date: Thu Jan 01 00:00:00 1970 +0000
1786 | summary: content3
1786 | summary: content3
1787 |
1787 |
1788 o changeset: 3:15b2327059e5
1788 o changeset: 3:15b2327059e5
1789 | user: test
1789 | user: test
1790 | date: Thu Jan 01 00:00:00 1970 +0000
1790 | date: Thu Jan 01 00:00:00 1970 +0000
1791 | summary: content2
1791 | summary: content2
1792 |
1792 |
1793 o changeset: 2:2029acd1168c
1793 o changeset: 2:2029acd1168c
1794 | parent: 0:ae0a3c9f9e95
1794 | parent: 0:ae0a3c9f9e95
1795 | user: test
1795 | user: test
1796 | date: Thu Jan 01 00:00:00 1970 +0000
1796 | date: Thu Jan 01 00:00:00 1970 +0000
1797 | summary: unrelated
1797 | summary: unrelated
1798 |
1798 |
1799 | o changeset: 1:2294ae80ad84
1799 | o changeset: 1:2294ae80ad84
1800 |/ user: test
1800 |/ user: test
1801 | date: Thu Jan 01 00:00:00 1970 +0000
1801 | date: Thu Jan 01 00:00:00 1970 +0000
1802 | summary: content2
1802 | summary: content2
1803 |
1803 |
1804 o changeset: 0:ae0a3c9f9e95
1804 o changeset: 0:ae0a3c9f9e95
1805 user: test
1805 user: test
1806 date: Thu Jan 01 00:00:00 1970 +0000
1806 date: Thu Jan 01 00:00:00 1970 +0000
1807 summary: content1
1807 summary: content1
1808
1808
1809
1809
1810 log -f on the file should list the graft result.
1810 log -f on the file should list the graft result.
1811
1811
1812 $ hg log -Gf a
1812 $ hg log -Gf a
1813 @ changeset: 4:50b9b36e9c5d
1813 @ changeset: 4:50b9b36e9c5d
1814 | tag: tip
1814 | tag: tip
1815 | user: test
1815 | user: test
1816 | date: Thu Jan 01 00:00:00 1970 +0000
1816 | date: Thu Jan 01 00:00:00 1970 +0000
1817 | summary: content3
1817 | summary: content3
1818 |
1818 |
1819 o changeset: 3:15b2327059e5
1819 o changeset: 3:15b2327059e5
1820 | user: test
1820 | user: test
1821 | date: Thu Jan 01 00:00:00 1970 +0000
1821 | date: Thu Jan 01 00:00:00 1970 +0000
1822 | summary: content2
1822 | summary: content2
1823 |
1823 |
1824 o changeset: 0:ae0a3c9f9e95
1824 o changeset: 0:ae0a3c9f9e95
1825 user: test
1825 user: test
1826 date: Thu Jan 01 00:00:00 1970 +0000
1826 date: Thu Jan 01 00:00:00 1970 +0000
1827 summary: content1
1827 summary: content1
1828
1828
1829
1829
1830 plain log lists the original version
1830 plain log lists the original version
1831 (XXX we should probably list both)
1831 (XXX we should probably list both)
1832
1832
1833 $ hg log -G a
1833 $ hg log -G a
1834 @ changeset: 4:50b9b36e9c5d
1834 @ changeset: 4:50b9b36e9c5d
1835 | tag: tip
1835 | tag: tip
1836 | user: test
1836 | user: test
1837 | date: Thu Jan 01 00:00:00 1970 +0000
1837 | date: Thu Jan 01 00:00:00 1970 +0000
1838 | summary: content3
1838 | summary: content3
1839 |
1839 |
1840 | o changeset: 1:2294ae80ad84
1840 | o changeset: 1:2294ae80ad84
1841 |/ user: test
1841 |/ user: test
1842 | date: Thu Jan 01 00:00:00 1970 +0000
1842 | date: Thu Jan 01 00:00:00 1970 +0000
1843 | summary: content2
1843 | summary: content2
1844 |
1844 |
1845 o changeset: 0:ae0a3c9f9e95
1845 o changeset: 0:ae0a3c9f9e95
1846 user: test
1846 user: test
1847 date: Thu Jan 01 00:00:00 1970 +0000
1847 date: Thu Jan 01 00:00:00 1970 +0000
1848 summary: content1
1848 summary: content1
1849
1849
1850
1850
1851 hg log -f from the grafted changeset
1851 hg log -f from the grafted changeset
1852 (The bootstrap should properly take the topology in account)
1852 (The bootstrap should properly take the topology in account)
1853
1853
1854 $ hg up 'desc(content3)^'
1854 $ hg up 'desc(content3)^'
1855 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1855 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1856 $ hg log -Gf a
1856 $ hg log -Gf a
1857 @ changeset: 3:15b2327059e5
1857 @ changeset: 3:15b2327059e5
1858 | user: test
1858 | user: test
1859 | date: Thu Jan 01 00:00:00 1970 +0000
1859 | date: Thu Jan 01 00:00:00 1970 +0000
1860 | summary: content2
1860 | summary: content2
1861 |
1861 |
1862 o changeset: 0:ae0a3c9f9e95
1862 o changeset: 0:ae0a3c9f9e95
1863 user: test
1863 user: test
1864 date: Thu Jan 01 00:00:00 1970 +0000
1864 date: Thu Jan 01 00:00:00 1970 +0000
1865 summary: content1
1865 summary: content1
1866
1866
1867
1867
1868 Test that we use the first non-hidden changeset in that case.
1868 Test that we use the first non-hidden changeset in that case.
1869
1869
1870 (hide the changeset)
1870 (hide the changeset)
1871
1871
1872 $ hg log -T '{node}\n' -r 1
1872 $ hg log -T '{node}\n' -r 1
1873 2294ae80ad8447bc78383182eeac50cb049df623
1873 2294ae80ad8447bc78383182eeac50cb049df623
1874 $ hg debugobsolete 2294ae80ad8447bc78383182eeac50cb049df623
1874 $ hg debugobsolete 2294ae80ad8447bc78383182eeac50cb049df623
1875 $ hg log -G
1875 $ hg log -G
1876 o changeset: 4:50b9b36e9c5d
1876 o changeset: 4:50b9b36e9c5d
1877 | tag: tip
1877 | tag: tip
1878 | user: test
1878 | user: test
1879 | date: Thu Jan 01 00:00:00 1970 +0000
1879 | date: Thu Jan 01 00:00:00 1970 +0000
1880 | summary: content3
1880 | summary: content3
1881 |
1881 |
1882 @ changeset: 3:15b2327059e5
1882 @ changeset: 3:15b2327059e5
1883 | user: test
1883 | user: test
1884 | date: Thu Jan 01 00:00:00 1970 +0000
1884 | date: Thu Jan 01 00:00:00 1970 +0000
1885 | summary: content2
1885 | summary: content2
1886 |
1886 |
1887 o changeset: 2:2029acd1168c
1887 o changeset: 2:2029acd1168c
1888 | parent: 0:ae0a3c9f9e95
1888 | parent: 0:ae0a3c9f9e95
1889 | user: test
1889 | user: test
1890 | date: Thu Jan 01 00:00:00 1970 +0000
1890 | date: Thu Jan 01 00:00:00 1970 +0000
1891 | summary: unrelated
1891 | summary: unrelated
1892 |
1892 |
1893 o changeset: 0:ae0a3c9f9e95
1893 o changeset: 0:ae0a3c9f9e95
1894 user: test
1894 user: test
1895 date: Thu Jan 01 00:00:00 1970 +0000
1895 date: Thu Jan 01 00:00:00 1970 +0000
1896 summary: content1
1896 summary: content1
1897
1897
1898
1898
1899 Check that log on the file does not drop the file revision.
1899 Check that log on the file does not drop the file revision.
1900
1900
1901 $ hg log -G a
1901 $ hg log -G a
1902 o changeset: 4:50b9b36e9c5d
1902 o changeset: 4:50b9b36e9c5d
1903 | tag: tip
1903 | tag: tip
1904 | user: test
1904 | user: test
1905 | date: Thu Jan 01 00:00:00 1970 +0000
1905 | date: Thu Jan 01 00:00:00 1970 +0000
1906 | summary: content3
1906 | summary: content3
1907 |
1907 |
1908 @ changeset: 3:15b2327059e5
1908 @ changeset: 3:15b2327059e5
1909 | user: test
1909 | user: test
1910 | date: Thu Jan 01 00:00:00 1970 +0000
1910 | date: Thu Jan 01 00:00:00 1970 +0000
1911 | summary: content2
1911 | summary: content2
1912 |
1912 |
1913 o changeset: 0:ae0a3c9f9e95
1913 o changeset: 0:ae0a3c9f9e95
1914 user: test
1914 user: test
1915 date: Thu Jan 01 00:00:00 1970 +0000
1915 date: Thu Jan 01 00:00:00 1970 +0000
1916 summary: content1
1916 summary: content1
1917
1917
1918
1918
1919 Even when a head revision is linkrev-shadowed.
1919 Even when a head revision is linkrev-shadowed.
1920
1920
1921 $ hg log -T '{node}\n' -r 4
1921 $ hg log -T '{node}\n' -r 4
1922 50b9b36e9c5df2c6fc6dcefa8ad0da929e84aed2
1922 50b9b36e9c5df2c6fc6dcefa8ad0da929e84aed2
1923 $ hg debugobsolete 50b9b36e9c5df2c6fc6dcefa8ad0da929e84aed2
1923 $ hg debugobsolete 50b9b36e9c5df2c6fc6dcefa8ad0da929e84aed2
1924 $ hg log -G a
1924 $ hg log -G a
1925 @ changeset: 3:15b2327059e5
1925 @ changeset: 3:15b2327059e5
1926 | tag: tip
1926 | tag: tip
1927 | user: test
1927 | user: test
1928 | date: Thu Jan 01 00:00:00 1970 +0000
1928 | date: Thu Jan 01 00:00:00 1970 +0000
1929 | summary: content2
1929 | summary: content2
1930 |
1930 |
1931 o changeset: 0:ae0a3c9f9e95
1931 o changeset: 0:ae0a3c9f9e95
1932 user: test
1932 user: test
1933 date: Thu Jan 01 00:00:00 1970 +0000
1933 date: Thu Jan 01 00:00:00 1970 +0000
1934 summary: content1
1934 summary: content1
1935
1935
1936
1936
1937 $ cd ..
1937 $ cd ..
1938
1938
1939 Even when the file revision is missing from some head:
1939 Even when the file revision is missing from some head:
1940
1940
1941 $ hg init issue4490
1941 $ hg init issue4490
1942 $ cd issue4490
1942 $ cd issue4490
1943 $ echo '[experimental]' >> .hg/hgrc
1943 $ echo '[experimental]' >> .hg/hgrc
1944 $ echo 'evolution=createmarkers' >> .hg/hgrc
1944 $ echo 'evolution=createmarkers' >> .hg/hgrc
1945 $ echo a > a
1945 $ echo a > a
1946 $ hg ci -Am0
1946 $ hg ci -Am0
1947 adding a
1947 adding a
1948 $ echo b > b
1948 $ echo b > b
1949 $ hg ci -Am1
1949 $ hg ci -Am1
1950 adding b
1950 adding b
1951 $ echo B > b
1951 $ echo B > b
1952 $ hg ci --amend -m 1
1952 $ hg ci --amend -m 1
1953 $ hg up 0
1953 $ hg up 0
1954 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1954 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1955 $ echo c > c
1955 $ echo c > c
1956 $ hg ci -Am2
1956 $ hg ci -Am2
1957 adding c
1957 adding c
1958 created new head
1958 created new head
1959 $ hg up 'head() and not .'
1959 $ hg up 'head() and not .'
1960 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
1960 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
1961 $ hg log -G
1961 $ hg log -G
1962 o changeset: 4:db815d6d32e6
1962 o changeset: 4:db815d6d32e6
1963 | tag: tip
1963 | tag: tip
1964 | parent: 0:f7b1eb17ad24
1964 | parent: 0:f7b1eb17ad24
1965 | user: test
1965 | user: test
1966 | date: Thu Jan 01 00:00:00 1970 +0000
1966 | date: Thu Jan 01 00:00:00 1970 +0000
1967 | summary: 2
1967 | summary: 2
1968 |
1968 |
1969 | @ changeset: 3:9bc8ce7f9356
1969 | @ changeset: 3:9bc8ce7f9356
1970 |/ parent: 0:f7b1eb17ad24
1970 |/ parent: 0:f7b1eb17ad24
1971 | user: test
1971 | user: test
1972 | date: Thu Jan 01 00:00:00 1970 +0000
1972 | date: Thu Jan 01 00:00:00 1970 +0000
1973 | summary: 1
1973 | summary: 1
1974 |
1974 |
1975 o changeset: 0:f7b1eb17ad24
1975 o changeset: 0:f7b1eb17ad24
1976 user: test
1976 user: test
1977 date: Thu Jan 01 00:00:00 1970 +0000
1977 date: Thu Jan 01 00:00:00 1970 +0000
1978 summary: 0
1978 summary: 0
1979
1979
1980 $ hg log -f -G b
1980 $ hg log -f -G b
1981 @ changeset: 3:9bc8ce7f9356
1981 @ changeset: 3:9bc8ce7f9356
1982 | parent: 0:f7b1eb17ad24
1982 | parent: 0:f7b1eb17ad24
1983 | user: test
1983 | user: test
1984 | date: Thu Jan 01 00:00:00 1970 +0000
1984 | date: Thu Jan 01 00:00:00 1970 +0000
1985 | summary: 1
1985 | summary: 1
1986 |
1986 |
1987 $ hg log -G b
1987 $ hg log -G b
1988 @ changeset: 3:9bc8ce7f9356
1988 @ changeset: 3:9bc8ce7f9356
1989 | parent: 0:f7b1eb17ad24
1989 | parent: 0:f7b1eb17ad24
1990 | user: test
1990 | user: test
1991 | date: Thu Jan 01 00:00:00 1970 +0000
1991 | date: Thu Jan 01 00:00:00 1970 +0000
1992 | summary: 1
1992 | summary: 1
1993 |
1993 |
1994 $ cd ..
1994 $ cd ..
1995
1995
1996 Check proper report when the manifest changes but not the file issue4499
1996 Check proper report when the manifest changes but not the file issue4499
1997 ------------------------------------------------------------------------
1997 ------------------------------------------------------------------------
1998
1998
1999 $ hg init issue4499
1999 $ hg init issue4499
2000 $ cd issue4499
2000 $ cd issue4499
2001 $ for f in A B C D F E G H I J K L M N O P Q R S T U; do
2001 $ for f in A B C D F E G H I J K L M N O P Q R S T U; do
2002 > echo 1 > $f;
2002 > echo 1 > $f;
2003 > hg add $f;
2003 > hg add $f;
2004 > done
2004 > done
2005 $ hg commit -m 'A1B1C1'
2005 $ hg commit -m 'A1B1C1'
2006 $ echo 2 > A
2006 $ echo 2 > A
2007 $ echo 2 > B
2007 $ echo 2 > B
2008 $ echo 2 > C
2008 $ echo 2 > C
2009 $ hg commit -m 'A2B2C2'
2009 $ hg commit -m 'A2B2C2'
2010 $ hg up 0
2010 $ hg up 0
2011 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
2011 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
2012 $ echo 3 > A
2012 $ echo 3 > A
2013 $ echo 2 > B
2013 $ echo 2 > B
2014 $ echo 2 > C
2014 $ echo 2 > C
2015 $ hg commit -m 'A3B2C2'
2015 $ hg commit -m 'A3B2C2'
2016 created new head
2016 created new head
2017
2017
2018 $ hg log -G
2018 $ hg log -G
2019 @ changeset: 2:fe5fc3d0eb17
2019 @ changeset: 2:fe5fc3d0eb17
2020 | tag: tip
2020 | tag: tip
2021 | parent: 0:abf4f0e38563
2021 | parent: 0:abf4f0e38563
2022 | user: test
2022 | user: test
2023 | date: Thu Jan 01 00:00:00 1970 +0000
2023 | date: Thu Jan 01 00:00:00 1970 +0000
2024 | summary: A3B2C2
2024 | summary: A3B2C2
2025 |
2025 |
2026 | o changeset: 1:07dcc6b312c0
2026 | o changeset: 1:07dcc6b312c0
2027 |/ user: test
2027 |/ user: test
2028 | date: Thu Jan 01 00:00:00 1970 +0000
2028 | date: Thu Jan 01 00:00:00 1970 +0000
2029 | summary: A2B2C2
2029 | summary: A2B2C2
2030 |
2030 |
2031 o changeset: 0:abf4f0e38563
2031 o changeset: 0:abf4f0e38563
2032 user: test
2032 user: test
2033 date: Thu Jan 01 00:00:00 1970 +0000
2033 date: Thu Jan 01 00:00:00 1970 +0000
2034 summary: A1B1C1
2034 summary: A1B1C1
2035
2035
2036
2036
2037 Log -f on B should reports current changesets
2037 Log -f on B should reports current changesets
2038
2038
2039 $ hg log -fG B
2039 $ hg log -fG B
2040 @ changeset: 2:fe5fc3d0eb17
2040 @ changeset: 2:fe5fc3d0eb17
2041 | tag: tip
2041 | tag: tip
2042 | parent: 0:abf4f0e38563
2042 | parent: 0:abf4f0e38563
2043 | user: test
2043 | user: test
2044 | date: Thu Jan 01 00:00:00 1970 +0000
2044 | date: Thu Jan 01 00:00:00 1970 +0000
2045 | summary: A3B2C2
2045 | summary: A3B2C2
2046 |
2046 |
2047 o changeset: 0:abf4f0e38563
2047 o changeset: 0:abf4f0e38563
2048 user: test
2048 user: test
2049 date: Thu Jan 01 00:00:00 1970 +0000
2049 date: Thu Jan 01 00:00:00 1970 +0000
2050 summary: A1B1C1
2050 summary: A1B1C1
2051
2051
2052 $ cd ..
2052 $ cd ..
General Comments 0
You need to be logged in to leave comments. Login now