Show More
@@ -1,1014 +1,1015 | |||
|
1 | 1 | $ cat <<EOF >> $HGRCPATH |
|
2 | 2 | > [extensions] |
|
3 | 3 | > keyword = |
|
4 | 4 | > mq = |
|
5 | 5 | > notify = |
|
6 | 6 | > record = |
|
7 | 7 | > transplant = |
|
8 | 8 | > [ui] |
|
9 | 9 | > interactive = true |
|
10 | 10 | > EOF |
|
11 | 11 | |
|
12 | 12 | Run kwdemo before [keyword] files are set up |
|
13 | 13 | as it would succeed without uisetup otherwise |
|
14 | 14 | |
|
15 | 15 | $ hg --quiet kwdemo |
|
16 | 16 | [extensions] |
|
17 | 17 | keyword = |
|
18 | 18 | [keyword] |
|
19 | 19 | demo.txt = |
|
20 | 20 | [keywordmaps] |
|
21 | 21 | Author = {author|user} |
|
22 | 22 | Date = {date|utcdate} |
|
23 | 23 | Header = {root}/{file},v {node|short} {date|utcdate} {author|user} |
|
24 | 24 | Id = {file|basename},v {node|short} {date|utcdate} {author|user} |
|
25 | 25 | RCSFile = {file|basename},v |
|
26 | 26 | RCSfile = {file|basename},v |
|
27 | 27 | Revision = {node|short} |
|
28 | 28 | Source = {root}/{file},v |
|
29 | 29 | $Author: test $ |
|
30 | 30 | $Date: ????/??/?? ??:??:?? $ (glob) |
|
31 | 31 | $Header: */demo.txt,v ???????????? ????/??/?? ??:??:?? test $ (glob) |
|
32 | 32 | $Id: demo.txt,v ???????????? ????/??/?? ??:??:?? test $ (glob) |
|
33 | 33 | $RCSFile: demo.txt,v $ |
|
34 | 34 | $RCSfile: demo.txt,v $ |
|
35 | 35 | $Revision: ???????????? $ (glob) |
|
36 | 36 | $Source: */demo.txt,v $ (glob) |
|
37 | 37 | |
|
38 | 38 | $ hg --quiet kwdemo "Branch = {branches}" |
|
39 | 39 | [extensions] |
|
40 | 40 | keyword = |
|
41 | 41 | [keyword] |
|
42 | 42 | demo.txt = |
|
43 | 43 | [keywordmaps] |
|
44 | 44 | Branch = {branches} |
|
45 | 45 | $Branch: demobranch $ |
|
46 | 46 | |
|
47 | 47 | $ cat <<EOF >> $HGRCPATH |
|
48 | 48 | > [keyword] |
|
49 | 49 | > ** = |
|
50 | 50 | > b = ignore |
|
51 | 51 | > i = ignore |
|
52 | 52 | > [hooks] |
|
53 | 53 | > EOF |
|
54 | 54 | $ cp $HGRCPATH $HGRCPATH.nohooks |
|
55 | 55 | > cat <<EOF >> $HGRCPATH |
|
56 | 56 | > commit= |
|
57 | 57 | > commit.test=cp a hooktest |
|
58 | 58 | > EOF |
|
59 | 59 | |
|
60 | 60 | $ hg init Test-bndl |
|
61 | 61 | $ cd Test-bndl |
|
62 | 62 | |
|
63 | 63 | kwshrink should exit silently in empty/invalid repo |
|
64 | 64 | |
|
65 | 65 | $ hg kwshrink |
|
66 | 66 | |
|
67 | 67 | Symlinks cannot be created on Windows. |
|
68 | 68 | A bundle to test this was made with: |
|
69 | 69 | hg init t |
|
70 | 70 | cd t |
|
71 | 71 | echo a > a |
|
72 | 72 | ln -s a sym |
|
73 | 73 | hg add sym |
|
74 | 74 | hg ci -m addsym -u mercurial |
|
75 | 75 | hg bundle --base null ../test-keyword.hg |
|
76 | 76 | |
|
77 | 77 | $ hg pull -u "$TESTDIR"/test-keyword.hg |
|
78 | 78 | pulling from *test-keyword.hg (glob) |
|
79 | 79 | requesting all changes |
|
80 | 80 | adding changesets |
|
81 | 81 | adding manifests |
|
82 | 82 | adding file changes |
|
83 | 83 | added 1 changesets with 1 changes to 1 files |
|
84 | 84 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
85 | 85 | |
|
86 | 86 | $ echo 'expand $Id$' > a |
|
87 | 87 | $ echo 'do not process $Id:' >> a |
|
88 | 88 | $ echo 'xxx $' >> a |
|
89 | 89 | $ echo 'ignore $Id$' > b |
|
90 | 90 | |
|
91 | 91 | Output files as they were created |
|
92 | 92 | |
|
93 | 93 | $ cat a b |
|
94 | 94 | expand $Id$ |
|
95 | 95 | do not process $Id: |
|
96 | 96 | xxx $ |
|
97 | 97 | ignore $Id$ |
|
98 | 98 | |
|
99 | 99 | no kwfiles |
|
100 | 100 | |
|
101 | 101 | $ hg kwfiles |
|
102 | 102 | |
|
103 | 103 | untracked candidates |
|
104 | 104 | |
|
105 | 105 | $ hg -v kwfiles --unknown |
|
106 | 106 | k a |
|
107 | 107 | |
|
108 | 108 | Add files and check status |
|
109 | 109 | |
|
110 | 110 | $ hg addremove |
|
111 | 111 | adding a |
|
112 | 112 | adding b |
|
113 | 113 | $ hg status |
|
114 | 114 | A a |
|
115 | 115 | A b |
|
116 | 116 | |
|
117 | 117 | |
|
118 | 118 | Default keyword expansion including commit hook |
|
119 | 119 | Interrupted commit should not change state or run commit hook |
|
120 | 120 | |
|
121 | 121 | $ hg --debug commit |
|
122 | 122 | abort: empty commit message |
|
123 | 123 | [255] |
|
124 | 124 | $ hg status |
|
125 | 125 | A a |
|
126 | 126 | A b |
|
127 | 127 | |
|
128 | 128 | Commit with several checks |
|
129 | 129 | |
|
130 | 130 | $ hg --debug commit -mabsym -u 'User Name <user@example.com>' |
|
131 | 131 | a |
|
132 | 132 | b |
|
133 | 133 | overwriting a expanding keywords |
|
134 | 134 | running hook commit.test: cp a hooktest |
|
135 | 135 | committed changeset 1:ef63ca68695bc9495032c6fda1350c71e6d256e9 |
|
136 | 136 | $ hg status |
|
137 | 137 | ? hooktest |
|
138 | 138 | $ hg debugrebuildstate |
|
139 | 139 | $ hg --quiet identify |
|
140 | 140 | ef63ca68695b |
|
141 | 141 | |
|
142 | 142 | cat files in working directory with keywords expanded |
|
143 | 143 | |
|
144 | 144 | $ cat a b |
|
145 | 145 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
146 | 146 | do not process $Id: |
|
147 | 147 | xxx $ |
|
148 | 148 | ignore $Id$ |
|
149 | 149 | |
|
150 | 150 | hg cat files and symlink, no expansion |
|
151 | 151 | |
|
152 | 152 | $ hg cat sym a b && echo |
|
153 | 153 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
154 | 154 | do not process $Id: |
|
155 | 155 | xxx $ |
|
156 | 156 | ignore $Id$ |
|
157 | 157 | a |
|
158 | 158 | |
|
159 | 159 | Test hook execution |
|
160 | 160 | |
|
161 | 161 | $ diff a hooktest |
|
162 | 162 | |
|
163 | 163 | $ cp $HGRCPATH.nohooks $HGRCPATH |
|
164 | 164 | $ rm hooktest |
|
165 | 165 | |
|
166 | 166 | bundle |
|
167 | 167 | |
|
168 | 168 | $ hg bundle --base null ../kw.hg |
|
169 | 169 | 2 changesets found |
|
170 | 170 | $ cd .. |
|
171 | 171 | $ hg init Test |
|
172 | 172 | $ cd Test |
|
173 | 173 | |
|
174 | 174 | Notify on pull to check whether keywords stay as is in email |
|
175 | 175 | ie. if patch.diff wrapper acts as it should |
|
176 | 176 | |
|
177 | 177 | $ cat <<EOF >> $HGRCPATH |
|
178 | 178 | > [hooks] |
|
179 | 179 | > incoming.notify = python:hgext.notify.hook |
|
180 | 180 | > [notify] |
|
181 | 181 | > sources = pull |
|
182 | 182 | > diffstat = False |
|
183 | > maxsubject = 15 | |
|
183 | 184 | > [reposubs] |
|
184 | 185 | > * = Test |
|
185 | 186 | > EOF |
|
186 | 187 | |
|
187 | 188 | Pull from bundle and trigger notify |
|
188 | 189 | |
|
189 | 190 | $ hg pull -u ../kw.hg |
|
190 | 191 | pulling from ../kw.hg |
|
191 | 192 | requesting all changes |
|
192 | 193 | adding changesets |
|
193 | 194 | adding manifests |
|
194 | 195 | adding file changes |
|
195 | 196 | added 2 changesets with 3 changes to 3 files |
|
196 | 197 | Content-Type: text/plain; charset="us-ascii" |
|
197 | 198 | MIME-Version: 1.0 |
|
198 | 199 | Content-Transfer-Encoding: 7bit |
|
199 | 200 | Date: * (glob) |
|
200 |
Subject: changeset in |
|
|
201 | Subject: changeset in... | |
|
201 | 202 | From: mercurial |
|
202 | 203 | X-Hg-Notification: changeset a2392c293916 |
|
203 | 204 | Message-Id: <hg.a2392c293916*> (glob) |
|
204 | 205 | To: Test |
|
205 | 206 | |
|
206 | 207 | changeset a2392c293916 in $TESTTMP/Test |
|
207 | 208 | details: *cmd=changeset;node=a2392c293916 (glob) |
|
208 | 209 | description: |
|
209 | 210 | addsym |
|
210 | 211 | |
|
211 | 212 | diffs (6 lines): |
|
212 | 213 | |
|
213 | 214 | diff -r 000000000000 -r a2392c293916 sym |
|
214 | 215 | --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
|
215 | 216 | +++ b/sym Sat Feb 09 20:25:47 2008 +0100 |
|
216 | 217 | @@ -0,0 +1,1 @@ |
|
217 | 218 | +a |
|
218 | 219 | \ No newline at end of file |
|
219 | 220 | Content-Type: text/plain; charset="us-ascii" |
|
220 | 221 | MIME-Version: 1.0 |
|
221 | 222 | Content-Transfer-Encoding: 7bit |
|
222 | 223 | Date:* (glob) |
|
223 |
Subject: changeset in |
|
|
224 | Subject: changeset in... | |
|
224 | 225 | From: User Name <user@example.com> |
|
225 | 226 | X-Hg-Notification: changeset ef63ca68695b |
|
226 | 227 | Message-Id: <hg.ef63ca68695b*> (glob) |
|
227 | 228 | To: Test |
|
228 | 229 | |
|
229 | 230 | changeset ef63ca68695b in $TESTTMP/Test |
|
230 | 231 | details: $TESTTMP/Test?cmd=changeset;node=ef63ca68695b |
|
231 | 232 | description: |
|
232 | 233 | absym |
|
233 | 234 | |
|
234 | 235 | diffs (12 lines): |
|
235 | 236 | |
|
236 | 237 | diff -r a2392c293916 -r ef63ca68695b a |
|
237 | 238 | --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
|
238 | 239 | +++ b/a Thu Jan 01 00:00:00 1970 +0000 |
|
239 | 240 | @@ -0,0 +1,3 @@ |
|
240 | 241 | +expand $Id$ |
|
241 | 242 | +do not process $Id: |
|
242 | 243 | +xxx $ |
|
243 | 244 | diff -r a2392c293916 -r ef63ca68695b b |
|
244 | 245 | --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
|
245 | 246 | +++ b/b Thu Jan 01 00:00:00 1970 +0000 |
|
246 | 247 | @@ -0,0 +1,1 @@ |
|
247 | 248 | +ignore $Id$ |
|
248 | 249 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
249 | 250 | |
|
250 | 251 | $ cp $HGRCPATH.nohooks $HGRCPATH |
|
251 | 252 | |
|
252 | 253 | Touch files and check with status |
|
253 | 254 | |
|
254 | 255 | $ touch a b |
|
255 | 256 | $ hg status |
|
256 | 257 | |
|
257 | 258 | Update and expand |
|
258 | 259 | |
|
259 | 260 | $ rm sym a b |
|
260 | 261 | $ hg update -C |
|
261 | 262 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
262 | 263 | $ cat a b |
|
263 | 264 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
264 | 265 | do not process $Id: |
|
265 | 266 | xxx $ |
|
266 | 267 | ignore $Id$ |
|
267 | 268 | |
|
268 | 269 | Check whether expansion is filewise |
|
269 | 270 | |
|
270 | 271 | $ echo '$Id$' > c |
|
271 | 272 | $ echo 'tests for different changenodes' >> c |
|
272 | 273 | |
|
273 | 274 | commit file c |
|
274 | 275 | |
|
275 | 276 | $ hg commit -A -mcndiff -d '1 0' -u 'User Name <user@example.com>' |
|
276 | 277 | adding c |
|
277 | 278 | |
|
278 | 279 | force expansion |
|
279 | 280 | |
|
280 | 281 | $ hg -v kwexpand |
|
281 | 282 | overwriting a expanding keywords |
|
282 | 283 | overwriting c expanding keywords |
|
283 | 284 | |
|
284 | 285 | compare changenodes in a and c |
|
285 | 286 | |
|
286 | 287 | $ cat a c |
|
287 | 288 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
288 | 289 | do not process $Id: |
|
289 | 290 | xxx $ |
|
290 | 291 | $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $ |
|
291 | 292 | tests for different changenodes |
|
292 | 293 | |
|
293 | 294 | record chunk |
|
294 | 295 | |
|
295 | 296 | $ python -c \ |
|
296 | 297 | > 'l=open("a").readlines();l.insert(1,"foo\n");l.append("bar\n");open("a","w").writelines(l);' |
|
297 | 298 | $ hg record -d '1 10' -m rectest<<EOF |
|
298 | 299 | > y |
|
299 | 300 | > y |
|
300 | 301 | > n |
|
301 | 302 | > EOF |
|
302 | 303 | diff --git a/a b/a |
|
303 | 304 | 2 hunks, 2 lines changed |
|
304 | 305 | examine changes to 'a'? [Ynsfdaq?] |
|
305 | 306 | @@ -1,3 +1,4 @@ |
|
306 | 307 | expand $Id$ |
|
307 | 308 | +foo |
|
308 | 309 | do not process $Id: |
|
309 | 310 | xxx $ |
|
310 | 311 | record change 1/2 to 'a'? [Ynsfdaq?] |
|
311 | 312 | @@ -2,2 +3,3 @@ |
|
312 | 313 | do not process $Id: |
|
313 | 314 | xxx $ |
|
314 | 315 | +bar |
|
315 | 316 | record change 2/2 to 'a'? [Ynsfdaq?] |
|
316 | 317 | |
|
317 | 318 | $ hg identify |
|
318 | 319 | d17e03c92c97+ tip |
|
319 | 320 | $ hg status |
|
320 | 321 | M a |
|
321 | 322 | |
|
322 | 323 | Cat modified file a |
|
323 | 324 | |
|
324 | 325 | $ cat a |
|
325 | 326 | expand $Id: a,v d17e03c92c97 1970/01/01 00:00:01 test $ |
|
326 | 327 | foo |
|
327 | 328 | do not process $Id: |
|
328 | 329 | xxx $ |
|
329 | 330 | bar |
|
330 | 331 | |
|
331 | 332 | Diff remaining chunk |
|
332 | 333 | |
|
333 | 334 | $ hg diff |
|
334 | 335 | diff -r d17e03c92c97 a |
|
335 | 336 | --- a/a Wed Dec 31 23:59:51 1969 -0000 |
|
336 | 337 | +++ b/a * (glob) |
|
337 | 338 | @@ -2,3 +2,4 @@ |
|
338 | 339 | foo |
|
339 | 340 | do not process $Id: |
|
340 | 341 | xxx $ |
|
341 | 342 | +bar |
|
342 | 343 | |
|
343 | 344 | $ hg rollback |
|
344 | 345 | rolling back to revision 2 (undo commit) |
|
345 | 346 | |
|
346 | 347 | Record all chunks in file a |
|
347 | 348 | |
|
348 | 349 | $ echo foo > msg |
|
349 | 350 | |
|
350 | 351 | - do not use "hg record -m" here! |
|
351 | 352 | |
|
352 | 353 | $ hg record -l msg -d '1 11'<<EOF |
|
353 | 354 | > y |
|
354 | 355 | > y |
|
355 | 356 | > y |
|
356 | 357 | > EOF |
|
357 | 358 | diff --git a/a b/a |
|
358 | 359 | 2 hunks, 2 lines changed |
|
359 | 360 | examine changes to 'a'? [Ynsfdaq?] |
|
360 | 361 | @@ -1,3 +1,4 @@ |
|
361 | 362 | expand $Id$ |
|
362 | 363 | +foo |
|
363 | 364 | do not process $Id: |
|
364 | 365 | xxx $ |
|
365 | 366 | record change 1/2 to 'a'? [Ynsfdaq?] |
|
366 | 367 | @@ -2,2 +3,3 @@ |
|
367 | 368 | do not process $Id: |
|
368 | 369 | xxx $ |
|
369 | 370 | +bar |
|
370 | 371 | record change 2/2 to 'a'? [Ynsfdaq?] |
|
371 | 372 | |
|
372 | 373 | File a should be clean |
|
373 | 374 | |
|
374 | 375 | $ hg status -A a |
|
375 | 376 | C a |
|
376 | 377 | |
|
377 | 378 | rollback and revert expansion |
|
378 | 379 | |
|
379 | 380 | $ cat a |
|
380 | 381 | expand $Id: a,v 59f969a3b52c 1970/01/01 00:00:01 test $ |
|
381 | 382 | foo |
|
382 | 383 | do not process $Id: |
|
383 | 384 | xxx $ |
|
384 | 385 | bar |
|
385 | 386 | $ hg --verbose rollback |
|
386 | 387 | rolling back to revision 2 (undo commit) |
|
387 | 388 | overwriting a expanding keywords |
|
388 | 389 | $ hg status a |
|
389 | 390 | M a |
|
390 | 391 | $ cat a |
|
391 | 392 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
392 | 393 | foo |
|
393 | 394 | do not process $Id: |
|
394 | 395 | xxx $ |
|
395 | 396 | bar |
|
396 | 397 | $ echo '$Id$' > y |
|
397 | 398 | $ echo '$Id$' > z |
|
398 | 399 | $ hg add y |
|
399 | 400 | $ hg commit -Am "rollback only" z |
|
400 | 401 | $ cat z |
|
401 | 402 | $Id: z,v 45a5d3adce53 1970/01/01 00:00:00 test $ |
|
402 | 403 | $ hg --verbose rollback |
|
403 | 404 | rolling back to revision 2 (undo commit) |
|
404 | 405 | overwriting z shrinking keywords |
|
405 | 406 | |
|
406 | 407 | Only z should be overwritten |
|
407 | 408 | |
|
408 | 409 | $ hg status a y z |
|
409 | 410 | M a |
|
410 | 411 | A y |
|
411 | 412 | A z |
|
412 | 413 | $ cat z |
|
413 | 414 | $Id$ |
|
414 | 415 | $ hg forget y z |
|
415 | 416 | $ rm y z |
|
416 | 417 | |
|
417 | 418 | $ hg update -C |
|
418 | 419 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
419 | 420 | |
|
420 | 421 | record added file |
|
421 | 422 | |
|
422 | 423 | $ echo '$Id$' > r |
|
423 | 424 | $ hg add r |
|
424 | 425 | $ hg -v record -l msg -d '1 12' r<<EOF |
|
425 | 426 | > y |
|
426 | 427 | > EOF |
|
427 | 428 | diff --git a/r b/r |
|
428 | 429 | new file mode 100644 |
|
429 | 430 | examine changes to 'r'? [Ynsfdaq?] |
|
430 | 431 | r |
|
431 | 432 | committed changeset 3:899491280810 |
|
432 | 433 | overwriting r expanding keywords |
|
433 | 434 | $ hg --verbose rollback |
|
434 | 435 | rolling back to revision 2 (undo commit) |
|
435 | 436 | overwriting r shrinking keywords |
|
436 | 437 | $ hg forget r |
|
437 | 438 | $ rm msg r |
|
438 | 439 | |
|
439 | 440 | Test patch queue repo |
|
440 | 441 | |
|
441 | 442 | $ hg init --mq |
|
442 | 443 | $ hg qimport -r tip -n mqtest.diff |
|
443 | 444 | $ hg commit --mq -m mqtest |
|
444 | 445 | |
|
445 | 446 | Keywords should not be expanded in patch |
|
446 | 447 | |
|
447 | 448 | $ cat .hg/patches/mqtest.diff |
|
448 | 449 | # HG changeset patch |
|
449 | 450 | # User User Name <user@example.com> |
|
450 | 451 | # Date 1 0 |
|
451 | 452 | # Node ID 40a904bbbe4cd4ab0a1f28411e35db26341a40ad |
|
452 | 453 | # Parent ef63ca68695bc9495032c6fda1350c71e6d256e9 |
|
453 | 454 | cndiff |
|
454 | 455 | |
|
455 | 456 | diff -r ef63ca68695b -r 40a904bbbe4c c |
|
456 | 457 | --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
|
457 | 458 | +++ b/c Thu Jan 01 00:00:01 1970 +0000 |
|
458 | 459 | @@ -0,0 +1,2 @@ |
|
459 | 460 | +$Id$ |
|
460 | 461 | +tests for different changenodes |
|
461 | 462 | |
|
462 | 463 | $ hg qpop |
|
463 | 464 | popping mqtest.diff |
|
464 | 465 | patch queue now empty |
|
465 | 466 | |
|
466 | 467 | qgoto, implying qpush, should expand |
|
467 | 468 | |
|
468 | 469 | $ hg qgoto mqtest.diff |
|
469 | 470 | applying mqtest.diff |
|
470 | 471 | now at: mqtest.diff |
|
471 | 472 | $ cat c |
|
472 | 473 | $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $ |
|
473 | 474 | tests for different changenodes |
|
474 | 475 | $ hg cat c |
|
475 | 476 | $Id: c,v 40a904bbbe4c 1970/01/01 00:00:01 user $ |
|
476 | 477 | tests for different changenodes |
|
477 | 478 | |
|
478 | 479 | Keywords should not be expanded in filelog |
|
479 | 480 | |
|
480 | 481 | $ hg --config 'extensions.keyword=!' cat c |
|
481 | 482 | $Id$ |
|
482 | 483 | tests for different changenodes |
|
483 | 484 | |
|
484 | 485 | qpop and move on |
|
485 | 486 | |
|
486 | 487 | $ hg qpop |
|
487 | 488 | popping mqtest.diff |
|
488 | 489 | patch queue now empty |
|
489 | 490 | |
|
490 | 491 | Copy and show added kwfiles |
|
491 | 492 | |
|
492 | 493 | $ hg cp a c |
|
493 | 494 | $ hg kwfiles |
|
494 | 495 | a |
|
495 | 496 | c |
|
496 | 497 | |
|
497 | 498 | Commit and show expansion in original and copy |
|
498 | 499 | |
|
499 | 500 | $ hg --debug commit -ma2c -d '1 0' -u 'User Name <user@example.com>' |
|
500 | 501 | c |
|
501 | 502 | c: copy a:0045e12f6c5791aac80ca6cbfd97709a88307292 |
|
502 | 503 | overwriting c expanding keywords |
|
503 | 504 | committed changeset 2:25736cf2f5cbe41f6be4e6784ef6ecf9f3bbcc7d |
|
504 | 505 | $ cat a c |
|
505 | 506 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
506 | 507 | do not process $Id: |
|
507 | 508 | xxx $ |
|
508 | 509 | expand $Id: c,v 25736cf2f5cb 1970/01/01 00:00:01 user $ |
|
509 | 510 | do not process $Id: |
|
510 | 511 | xxx $ |
|
511 | 512 | |
|
512 | 513 | Touch copied c and check its status |
|
513 | 514 | |
|
514 | 515 | $ touch c |
|
515 | 516 | $ hg status |
|
516 | 517 | |
|
517 | 518 | Copy kwfile to keyword ignored file unexpanding keywords |
|
518 | 519 | |
|
519 | 520 | $ hg --verbose copy a i |
|
520 | 521 | copying a to i |
|
521 | 522 | overwriting i shrinking keywords |
|
522 | 523 | $ head -n 1 i |
|
523 | 524 | expand $Id$ |
|
524 | 525 | $ hg forget i |
|
525 | 526 | $ rm i |
|
526 | 527 | |
|
527 | 528 | Copy ignored file to ignored file: no overwriting |
|
528 | 529 | |
|
529 | 530 | $ hg --verbose copy b i |
|
530 | 531 | copying b to i |
|
531 | 532 | $ hg forget i |
|
532 | 533 | $ rm i |
|
533 | 534 | |
|
534 | 535 | cp symlink (becomes regular file), and hg copy after |
|
535 | 536 | |
|
536 | 537 | $ cp sym i |
|
537 | 538 | $ ls -l i |
|
538 | 539 | -rw-r--r--* (glob) |
|
539 | 540 | $ head -1 i |
|
540 | 541 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
541 | 542 | $ hg copy --after --verbose sym i |
|
542 | 543 | copying sym to i |
|
543 | 544 | overwriting i shrinking keywords |
|
544 | 545 | $ head -1 i |
|
545 | 546 | expand $Id$ |
|
546 | 547 | $ hg forget i |
|
547 | 548 | $ rm i |
|
548 | 549 | |
|
549 | 550 | Test different options of hg kwfiles |
|
550 | 551 | |
|
551 | 552 | $ hg kwfiles |
|
552 | 553 | a |
|
553 | 554 | c |
|
554 | 555 | $ hg -v kwfiles --ignore |
|
555 | 556 | I b |
|
556 | 557 | I sym |
|
557 | 558 | $ hg kwfiles --all |
|
558 | 559 | K a |
|
559 | 560 | K c |
|
560 | 561 | I b |
|
561 | 562 | I sym |
|
562 | 563 | |
|
563 | 564 | Diff specific revision |
|
564 | 565 | |
|
565 | 566 | $ hg diff --rev 1 |
|
566 | 567 | diff -r ef63ca68695b c |
|
567 | 568 | --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
|
568 | 569 | +++ b/c * (glob) |
|
569 | 570 | @@ -0,0 +1,3 @@ |
|
570 | 571 | +expand $Id$ |
|
571 | 572 | +do not process $Id: |
|
572 | 573 | +xxx $ |
|
573 | 574 | |
|
574 | 575 | Status after rollback: |
|
575 | 576 | |
|
576 | 577 | $ hg rollback |
|
577 | 578 | rolling back to revision 1 (undo commit) |
|
578 | 579 | $ hg status |
|
579 | 580 | A c |
|
580 | 581 | $ hg update --clean |
|
581 | 582 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
582 | 583 | |
|
583 | 584 | Custom keywordmaps as argument to kwdemo |
|
584 | 585 | |
|
585 | 586 | $ hg --quiet kwdemo "Xinfo = {author}: {desc}" |
|
586 | 587 | [extensions] |
|
587 | 588 | keyword = |
|
588 | 589 | [keyword] |
|
589 | 590 | ** = |
|
590 | 591 | b = ignore |
|
591 | 592 | demo.txt = |
|
592 | 593 | i = ignore |
|
593 | 594 | [keywordmaps] |
|
594 | 595 | Xinfo = {author}: {desc} |
|
595 | 596 | $Xinfo: test: hg keyword configuration and expansion example $ |
|
596 | 597 | |
|
597 | 598 | Configure custom keywordmaps |
|
598 | 599 | |
|
599 | 600 | $ cat <<EOF >>$HGRCPATH |
|
600 | 601 | > [keywordmaps] |
|
601 | 602 | > Id = {file} {node|short} {date|rfc822date} {author|user} |
|
602 | 603 | > Xinfo = {author}: {desc} |
|
603 | 604 | > EOF |
|
604 | 605 | |
|
605 | 606 | Cat and hg cat files before custom expansion |
|
606 | 607 | |
|
607 | 608 | $ cat a b |
|
608 | 609 | expand $Id: a,v ef63ca68695b 1970/01/01 00:00:00 user $ |
|
609 | 610 | do not process $Id: |
|
610 | 611 | xxx $ |
|
611 | 612 | ignore $Id$ |
|
612 | 613 | $ hg cat sym a b && echo |
|
613 | 614 | expand $Id: a ef63ca68695b Thu, 01 Jan 1970 00:00:00 +0000 user $ |
|
614 | 615 | do not process $Id: |
|
615 | 616 | xxx $ |
|
616 | 617 | ignore $Id$ |
|
617 | 618 | a |
|
618 | 619 | |
|
619 | 620 | Write custom keyword and prepare multiline commit message |
|
620 | 621 | |
|
621 | 622 | $ echo '$Xinfo$' >> a |
|
622 | 623 | $ cat <<EOF >> log |
|
623 | 624 | > firstline |
|
624 | 625 | > secondline |
|
625 | 626 | > EOF |
|
626 | 627 | |
|
627 | 628 | Interrupted commit should not change state |
|
628 | 629 | |
|
629 | 630 | $ hg commit |
|
630 | 631 | abort: empty commit message |
|
631 | 632 | [255] |
|
632 | 633 | $ hg status |
|
633 | 634 | M a |
|
634 | 635 | ? c |
|
635 | 636 | ? log |
|
636 | 637 | |
|
637 | 638 | Commit with multiline message and custom expansion |
|
638 | 639 | |
|
639 | 640 | $ hg --debug commit -l log -d '2 0' -u 'User Name <user@example.com>' |
|
640 | 641 | a |
|
641 | 642 | overwriting a expanding keywords |
|
642 | 643 | committed changeset 2:bb948857c743469b22bbf51f7ec8112279ca5d83 |
|
643 | 644 | $ rm log |
|
644 | 645 | |
|
645 | 646 | Stat, verify and show custom expansion (firstline) |
|
646 | 647 | |
|
647 | 648 | $ hg status |
|
648 | 649 | ? c |
|
649 | 650 | $ hg verify |
|
650 | 651 | checking changesets |
|
651 | 652 | checking manifests |
|
652 | 653 | crosschecking files in changesets and manifests |
|
653 | 654 | checking files |
|
654 | 655 | 3 files, 3 changesets, 4 total revisions |
|
655 | 656 | $ cat a b |
|
656 | 657 | expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $ |
|
657 | 658 | do not process $Id: |
|
658 | 659 | xxx $ |
|
659 | 660 | $Xinfo: User Name <user@example.com>: firstline $ |
|
660 | 661 | ignore $Id$ |
|
661 | 662 | $ hg cat sym a b && echo |
|
662 | 663 | expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $ |
|
663 | 664 | do not process $Id: |
|
664 | 665 | xxx $ |
|
665 | 666 | $Xinfo: User Name <user@example.com>: firstline $ |
|
666 | 667 | ignore $Id$ |
|
667 | 668 | a |
|
668 | 669 | |
|
669 | 670 | annotate |
|
670 | 671 | |
|
671 | 672 | $ hg annotate a |
|
672 | 673 | 1: expand $Id$ |
|
673 | 674 | 1: do not process $Id: |
|
674 | 675 | 1: xxx $ |
|
675 | 676 | 2: $Xinfo$ |
|
676 | 677 | |
|
677 | 678 | remove with status checks |
|
678 | 679 | |
|
679 | 680 | $ hg debugrebuildstate |
|
680 | 681 | $ hg remove a |
|
681 | 682 | $ hg --debug commit -m rma |
|
682 | 683 | committed changeset 3:d14c712653769de926994cf7fbb06c8fbd68f012 |
|
683 | 684 | $ hg status |
|
684 | 685 | ? c |
|
685 | 686 | |
|
686 | 687 | Rollback, revert, and check expansion |
|
687 | 688 | |
|
688 | 689 | $ hg rollback |
|
689 | 690 | rolling back to revision 2 (undo commit) |
|
690 | 691 | $ hg status |
|
691 | 692 | R a |
|
692 | 693 | ? c |
|
693 | 694 | $ hg revert --no-backup --rev tip a |
|
694 | 695 | $ cat a |
|
695 | 696 | expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $ |
|
696 | 697 | do not process $Id: |
|
697 | 698 | xxx $ |
|
698 | 699 | $Xinfo: User Name <user@example.com>: firstline $ |
|
699 | 700 | |
|
700 | 701 | Clone to test global and local configurations |
|
701 | 702 | |
|
702 | 703 | $ cd .. |
|
703 | 704 | |
|
704 | 705 | Expansion in destinaton with global configuration |
|
705 | 706 | |
|
706 | 707 | $ hg --quiet clone Test globalconf |
|
707 | 708 | $ cat globalconf/a |
|
708 | 709 | expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $ |
|
709 | 710 | do not process $Id: |
|
710 | 711 | xxx $ |
|
711 | 712 | $Xinfo: User Name <user@example.com>: firstline $ |
|
712 | 713 | |
|
713 | 714 | No expansion in destination with local configuration in origin only |
|
714 | 715 | |
|
715 | 716 | $ hg --quiet --config 'keyword.**=ignore' clone Test localconf |
|
716 | 717 | $ cat localconf/a |
|
717 | 718 | expand $Id$ |
|
718 | 719 | do not process $Id: |
|
719 | 720 | xxx $ |
|
720 | 721 | $Xinfo$ |
|
721 | 722 | |
|
722 | 723 | Clone to test incoming |
|
723 | 724 | |
|
724 | 725 | $ hg clone -r1 Test Test-a |
|
725 | 726 | requesting all changes |
|
726 | 727 | adding changesets |
|
727 | 728 | adding manifests |
|
728 | 729 | adding file changes |
|
729 | 730 | added 2 changesets with 3 changes to 3 files |
|
730 | 731 | updating to branch default |
|
731 | 732 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
732 | 733 | $ cd Test-a |
|
733 | 734 | $ cat <<EOF >> .hg/hgrc |
|
734 | 735 | > [paths] |
|
735 | 736 | > default = ../Test |
|
736 | 737 | > EOF |
|
737 | 738 | $ hg incoming |
|
738 | 739 | comparing with $TESTTMP/Test |
|
739 | 740 | searching for changes |
|
740 | 741 | changeset: 2:bb948857c743 |
|
741 | 742 | tag: tip |
|
742 | 743 | user: User Name <user@example.com> |
|
743 | 744 | date: Thu Jan 01 00:00:02 1970 +0000 |
|
744 | 745 | summary: firstline |
|
745 | 746 | |
|
746 | 747 | Imported patch should not be rejected |
|
747 | 748 | |
|
748 | 749 | $ python -c \ |
|
749 | 750 | > 'import re; s=re.sub("(Id.*)","\\1 rejecttest",open("a").read()); open("a","wb").write(s);' |
|
750 | 751 | $ hg --debug commit -m'rejects?' -d '3 0' -u 'User Name <user@example.com>' |
|
751 | 752 | a |
|
752 | 753 | overwriting a expanding keywords |
|
753 | 754 | committed changeset 2:85e279d709ffc28c9fdd1b868570985fc3d87082 |
|
754 | 755 | $ hg export -o ../rejecttest.diff tip |
|
755 | 756 | $ cd ../Test |
|
756 | 757 | $ hg import ../rejecttest.diff |
|
757 | 758 | applying ../rejecttest.diff |
|
758 | 759 | $ cat a b |
|
759 | 760 | expand $Id: a 4e0994474d25 Thu, 01 Jan 1970 00:00:03 +0000 user $ rejecttest |
|
760 | 761 | do not process $Id: rejecttest |
|
761 | 762 | xxx $ |
|
762 | 763 | $Xinfo: User Name <user@example.com>: rejects? $ |
|
763 | 764 | ignore $Id$ |
|
764 | 765 | |
|
765 | 766 | $ hg rollback |
|
766 | 767 | rolling back to revision 2 (undo commit) |
|
767 | 768 | $ hg update --clean |
|
768 | 769 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
769 | 770 | |
|
770 | 771 | kwexpand/kwshrink on selected files |
|
771 | 772 | |
|
772 | 773 | $ mkdir x |
|
773 | 774 | $ hg copy a x/a |
|
774 | 775 | $ hg --verbose kwexpand a |
|
775 | 776 | overwriting a expanding keywords |
|
776 | 777 | |
|
777 | 778 | kwexpand x/a should abort |
|
778 | 779 | |
|
779 | 780 | $ hg --verbose kwexpand x/a |
|
780 | 781 | abort: outstanding uncommitted changes |
|
781 | 782 | [255] |
|
782 | 783 | $ cd x |
|
783 | 784 | $ hg --debug commit -m xa -d '3 0' -u 'User Name <user@example.com>' |
|
784 | 785 | x/a |
|
785 | 786 | x/a: copy a:779c764182ce5d43e2b1eb66ce06d7b47bfe342e |
|
786 | 787 | overwriting x/a expanding keywords |
|
787 | 788 | committed changeset 3:b4560182a3f9a358179fd2d835c15e9da379c1e4 |
|
788 | 789 | $ cat a |
|
789 | 790 | expand $Id: x/a b4560182a3f9 Thu, 01 Jan 1970 00:00:03 +0000 user $ |
|
790 | 791 | do not process $Id: |
|
791 | 792 | xxx $ |
|
792 | 793 | $Xinfo: User Name <user@example.com>: xa $ |
|
793 | 794 | |
|
794 | 795 | kwshrink a inside directory x |
|
795 | 796 | |
|
796 | 797 | $ hg --verbose kwshrink a |
|
797 | 798 | overwriting x/a shrinking keywords |
|
798 | 799 | $ cat a |
|
799 | 800 | expand $Id$ |
|
800 | 801 | do not process $Id: |
|
801 | 802 | xxx $ |
|
802 | 803 | $Xinfo$ |
|
803 | 804 | $ cd .. |
|
804 | 805 | |
|
805 | 806 | kwexpand nonexistent |
|
806 | 807 | |
|
807 | 808 | $ hg kwexpand nonexistent |
|
808 | 809 | nonexistent:* (glob) |
|
809 | 810 | |
|
810 | 811 | |
|
811 | 812 | hg serve |
|
812 | 813 | - expand with hgweb file |
|
813 | 814 | - no expansion with hgweb annotate/changeset/filediff |
|
814 | 815 | - check errors |
|
815 | 816 | |
|
816 | 817 | $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log |
|
817 | 818 | $ cat hg.pid >> $DAEMON_PIDS |
|
818 | 819 | $ $TESTDIR/get-with-headers.py localhost:$HGPORT '/file/tip/a/?style=raw' |
|
819 | 820 | 200 Script output follows |
|
820 | 821 | |
|
821 | 822 | expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $ |
|
822 | 823 | do not process $Id: |
|
823 | 824 | xxx $ |
|
824 | 825 | $Xinfo: User Name <user@example.com>: firstline $ |
|
825 | 826 | $ $TESTDIR/get-with-headers.py localhost:$HGPORT '/annotate/tip/a/?style=raw' |
|
826 | 827 | 200 Script output follows |
|
827 | 828 | |
|
828 | 829 | |
|
829 | 830 | user@1: expand $Id$ |
|
830 | 831 | user@1: do not process $Id: |
|
831 | 832 | user@1: xxx $ |
|
832 | 833 | user@2: $Xinfo$ |
|
833 | 834 | |
|
834 | 835 | |
|
835 | 836 | |
|
836 | 837 | |
|
837 | 838 | $ $TESTDIR/get-with-headers.py localhost:$HGPORT '/rev/tip/?style=raw' |
|
838 | 839 | 200 Script output follows |
|
839 | 840 | |
|
840 | 841 | |
|
841 | 842 | # HG changeset patch |
|
842 | 843 | # User User Name <user@example.com> |
|
843 | 844 | # Date 3 0 |
|
844 | 845 | # Node ID b4560182a3f9a358179fd2d835c15e9da379c1e4 |
|
845 | 846 | # Parent bb948857c743469b22bbf51f7ec8112279ca5d83 |
|
846 | 847 | xa |
|
847 | 848 | |
|
848 | 849 | diff -r bb948857c743 -r b4560182a3f9 x/a |
|
849 | 850 | --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
|
850 | 851 | +++ b/x/a Thu Jan 01 00:00:03 1970 +0000 |
|
851 | 852 | @@ -0,0 +1,4 @@ |
|
852 | 853 | +expand $Id$ |
|
853 | 854 | +do not process $Id: |
|
854 | 855 | +xxx $ |
|
855 | 856 | +$Xinfo$ |
|
856 | 857 | |
|
857 | 858 | $ $TESTDIR/get-with-headers.py localhost:$HGPORT '/diff/bb948857c743/a?style=raw' |
|
858 | 859 | 200 Script output follows |
|
859 | 860 | |
|
860 | 861 | |
|
861 | 862 | diff -r ef63ca68695b -r bb948857c743 a |
|
862 | 863 | --- a/a Thu Jan 01 00:00:00 1970 +0000 |
|
863 | 864 | +++ b/a Thu Jan 01 00:00:02 1970 +0000 |
|
864 | 865 | @@ -1,3 +1,4 @@ |
|
865 | 866 | expand $Id$ |
|
866 | 867 | do not process $Id: |
|
867 | 868 | xxx $ |
|
868 | 869 | +$Xinfo$ |
|
869 | 870 | |
|
870 | 871 | |
|
871 | 872 | |
|
872 | 873 | |
|
873 | 874 | $ cat errors.log |
|
874 | 875 | |
|
875 | 876 | Prepare merge and resolve tests |
|
876 | 877 | |
|
877 | 878 | $ echo '$Id$' > m |
|
878 | 879 | $ hg add m |
|
879 | 880 | $ hg commit -m 4kw |
|
880 | 881 | $ echo foo >> m |
|
881 | 882 | $ hg commit -m 5foo |
|
882 | 883 | |
|
883 | 884 | simplemerge |
|
884 | 885 | |
|
885 | 886 | $ hg update 4 |
|
886 | 887 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
887 | 888 | $ echo foo >> m |
|
888 | 889 | $ hg commit -m 6foo |
|
889 | 890 | created new head |
|
890 | 891 | $ hg merge |
|
891 | 892 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
892 | 893 | (branch merge, don't forget to commit) |
|
893 | 894 | $ hg commit -m simplemerge |
|
894 | 895 | $ cat m |
|
895 | 896 | $Id: m 27d48ee14f67 Thu, 01 Jan 1970 00:00:00 +0000 test $ |
|
896 | 897 | foo |
|
897 | 898 | |
|
898 | 899 | conflict: keyword should stay outside conflict zone |
|
899 | 900 | |
|
900 | 901 | $ hg update 4 |
|
901 | 902 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
902 | 903 | $ echo bar >> m |
|
903 | 904 | $ hg commit -m 8bar |
|
904 | 905 | created new head |
|
905 | 906 | $ hg merge |
|
906 | 907 | merging m |
|
907 | 908 | warning: conflicts during merge. |
|
908 | 909 | merging m failed! |
|
909 | 910 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
910 | 911 | use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon |
|
911 | 912 | [1] |
|
912 | 913 | $ cat m |
|
913 | 914 | $Id$ |
|
914 | 915 | <<<<<<< local |
|
915 | 916 | bar |
|
916 | 917 | ======= |
|
917 | 918 | foo |
|
918 | 919 | >>>>>>> other |
|
919 | 920 | |
|
920 | 921 | resolve to local |
|
921 | 922 | |
|
922 | 923 | $ HGMERGE=internal:local hg resolve -a |
|
923 | 924 | $ hg commit -m localresolve |
|
924 | 925 | $ cat m |
|
925 | 926 | $Id: m 41efa6d38e9b Thu, 01 Jan 1970 00:00:00 +0000 test $ |
|
926 | 927 | bar |
|
927 | 928 | |
|
928 | 929 | Test restricted mode with transplant -b |
|
929 | 930 | |
|
930 | 931 | $ hg update 6 |
|
931 | 932 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
932 | 933 | $ hg branch foo |
|
933 | 934 | marked working directory as branch foo |
|
934 | 935 | $ mv a a.bak |
|
935 | 936 | $ echo foobranch > a |
|
936 | 937 | $ cat a.bak >> a |
|
937 | 938 | $ rm a.bak |
|
938 | 939 | $ hg commit -m 9foobranch |
|
939 | 940 | $ hg update default |
|
940 | 941 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
941 | 942 | $ hg -y transplant -b foo tip |
|
942 | 943 | applying 4aa30d025d50 |
|
943 | 944 | 4aa30d025d50 transplanted to 5a4da427c162 |
|
944 | 945 | |
|
945 | 946 | Expansion in changeset but not in file |
|
946 | 947 | |
|
947 | 948 | $ hg tip -p |
|
948 | 949 | changeset: 11:5a4da427c162 |
|
949 | 950 | tag: tip |
|
950 | 951 | parent: 9:41efa6d38e9b |
|
951 | 952 | user: test |
|
952 | 953 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
953 | 954 | summary: 9foobranch |
|
954 | 955 | |
|
955 | 956 | diff -r 41efa6d38e9b -r 5a4da427c162 a |
|
956 | 957 | --- a/a Thu Jan 01 00:00:00 1970 +0000 |
|
957 | 958 | +++ b/a Thu Jan 01 00:00:00 1970 +0000 |
|
958 | 959 | @@ -1,3 +1,4 @@ |
|
959 | 960 | +foobranch |
|
960 | 961 | expand $Id$ |
|
961 | 962 | do not process $Id: |
|
962 | 963 | xxx $ |
|
963 | 964 | |
|
964 | 965 | $ head -n 2 a |
|
965 | 966 | foobranch |
|
966 | 967 | expand $Id: a 5a4da427c162 Thu, 01 Jan 1970 00:00:00 +0000 test $ |
|
967 | 968 | |
|
968 | 969 | Turn off expansion |
|
969 | 970 | |
|
970 | 971 | $ hg -q rollback |
|
971 | 972 | $ hg -q update -C |
|
972 | 973 | |
|
973 | 974 | kwshrink with unknown file u |
|
974 | 975 | |
|
975 | 976 | $ cp a u |
|
976 | 977 | $ hg --verbose kwshrink |
|
977 | 978 | overwriting a shrinking keywords |
|
978 | 979 | overwriting m shrinking keywords |
|
979 | 980 | overwriting x/a shrinking keywords |
|
980 | 981 | |
|
981 | 982 | Keywords shrunk in working directory, but not yet disabled |
|
982 | 983 | - cat shows unexpanded keywords |
|
983 | 984 | - hg cat shows expanded keywords |
|
984 | 985 | |
|
985 | 986 | $ cat a b |
|
986 | 987 | expand $Id$ |
|
987 | 988 | do not process $Id: |
|
988 | 989 | xxx $ |
|
989 | 990 | $Xinfo$ |
|
990 | 991 | ignore $Id$ |
|
991 | 992 | $ hg cat sym a b && echo |
|
992 | 993 | expand $Id: a bb948857c743 Thu, 01 Jan 1970 00:00:02 +0000 user $ |
|
993 | 994 | do not process $Id: |
|
994 | 995 | xxx $ |
|
995 | 996 | $Xinfo: User Name <user@example.com>: firstline $ |
|
996 | 997 | ignore $Id$ |
|
997 | 998 | a |
|
998 | 999 | |
|
999 | 1000 | Now disable keyword expansion |
|
1000 | 1001 | |
|
1001 | 1002 | $ rm "$HGRCPATH" |
|
1002 | 1003 | $ cat a b |
|
1003 | 1004 | expand $Id$ |
|
1004 | 1005 | do not process $Id: |
|
1005 | 1006 | xxx $ |
|
1006 | 1007 | $Xinfo$ |
|
1007 | 1008 | ignore $Id$ |
|
1008 | 1009 | $ hg cat sym a b && echo |
|
1009 | 1010 | expand $Id$ |
|
1010 | 1011 | do not process $Id: |
|
1011 | 1012 | xxx $ |
|
1012 | 1013 | $Xinfo$ |
|
1013 | 1014 | ignore $Id$ |
|
1014 | 1015 | a |
General Comments 0
You need to be logged in to leave comments.
Login now