changeset 16173 | 9178d284b880 |
parent 16172 | db75321c7a0e |
child 16174 | 0a73c4bd9f47 |
16172:db75321c7a0e | 16173:9178d284b880 |
---|---|
1452 abort: unknown revision 'not-a-branch'! |
1452 abort: unknown revision 'not-a-branch'! |
1453 $ testlog -b default -b branch --only-branch branch |
1453 $ testlog -b default -b branch --only-branch branch |
1454 ('group', ('group', ('or', ('or', ('func', ('symbol', 'branch'), ('string', 'default')), ('func', ('symbol', 'branch'), ('string', 'branch'))), ('func', ('symbol', 'branch'), ('string', 'branch'))))) |
1454 ('group', ('group', ('or', ('or', ('func', ('symbol', 'branch'), ('string', 'default')), ('func', ('symbol', 'branch'), ('string', 'branch'))), ('func', ('symbol', 'branch'), ('string', 'branch'))))) |
1455 $ testlog -k expand -k merge |
1455 $ testlog -k expand -k merge |
1456 ('group', ('group', ('or', ('func', ('symbol', 'keyword'), ('string', 'expand')), ('func', ('symbol', 'keyword'), ('string', 'merge'))))) |
1456 ('group', ('group', ('or', ('func', ('symbol', 'keyword'), ('string', 'expand')), ('func', ('symbol', 'keyword'), ('string', 'merge'))))) |
1457 $ hg log -G --follow --template 'nodetag {rev}\n' | grep nodetag | wc -l |
|
1458 \s*36 (re) |
|
1459 $ hg log -G --removed --template 'nodetag {rev}\n' | grep nodetag | wc -l |
1457 $ hg log -G --removed --template 'nodetag {rev}\n' | grep nodetag | wc -l |
1460 \s*0 (re) |
1458 \s*0 (re) |
1461 $ hg log -G --only-merges --template 'nodetag {rev}\n' | grep nodetag | wc -l |
1459 $ hg log -G --only-merges --template 'nodetag {rev}\n' | grep nodetag | wc -l |
1462 \s*28 (re) |
1460 \s*28 (re) |
1463 $ hg log -G --no-merges --template 'nodetag {rev}\n' |
1461 $ hg log -G --no-merges --template 'nodetag {rev}\n' |
1490 $ hg log -G -d 'brace ) in a date' |
1488 $ hg log -G -d 'brace ) in a date' |
1491 abort: invalid date: 'brace ) in a date' |
1489 abort: invalid date: 'brace ) in a date' |
1492 [255] |
1490 [255] |
1493 $ testlog --prune 31 --prune 32 |
1491 $ testlog --prune 31 --prune 32 |
1494 ('group', ('group', ('and', ('not', ('group', ('or', ('string', '31'), ('func', ('symbol', 'ancestors'), ('string', '31'))))), ('not', ('group', ('or', ('string', '32'), ('func', ('symbol', 'ancestors'), ('string', '32')))))))) |
1492 ('group', ('group', ('and', ('not', ('group', ('or', ('string', '31'), ('func', ('symbol', 'ancestors'), ('string', '31'))))), ('not', ('group', ('or', ('string', '32'), ('func', ('symbol', 'ancestors'), ('string', '32')))))))) |
1495 $ hg log -G --follow a |
1493 |
1496 abort: -G/--graph option is incompatible with --follow with file argument |
1494 Dedicated repo for --follow and paths filtering. The g is crafted to |
1497 [255] |
1495 have 2 filelog topological heads in a linear changeset graph. |
1498 |
|
1499 |
|
1500 Dedicated repo for --follow and paths filtering |
|
1501 |
1496 |
1502 $ cd .. |
1497 $ cd .. |
1503 $ hg init follow |
1498 $ hg init follow |
1504 $ cd follow |
1499 $ cd follow |
1505 $ echo a > a |
1500 $ echo a > a |
1506 $ echo aa > aa |
1501 $ echo aa > aa |
1502 $ echo f > f |
|
1507 $ hg ci -Am "add a" |
1503 $ hg ci -Am "add a" |
1508 adding a |
1504 adding a |
1509 adding aa |
1505 adding aa |
1506 adding f |
|
1510 $ hg cp a b |
1507 $ hg cp a b |
1508 $ hg cp f g |
|
1511 $ hg ci -m "copy a b" |
1509 $ hg ci -m "copy a b" |
1512 $ mkdir dir |
1510 $ mkdir dir |
1513 $ hg mv b dir |
1511 $ hg mv b dir |
1512 $ echo g >> g |
|
1513 $ echo f >> f |
|
1514 $ hg ci -m "mv b dir/b" |
1514 $ hg ci -m "mv b dir/b" |
1515 $ hg mv a b |
1515 $ hg mv a b |
1516 $ hg cp -f f g |
|
1516 $ echo a > d |
1517 $ echo a > d |
1517 $ hg add d |
1518 $ hg add d |
1518 $ hg ci -m "mv a b; add d" |
1519 $ hg ci -m "mv a b; add d" |
1519 $ hg mv dir/b e |
1520 $ hg mv dir/b e |
1520 $ hg ci -m "mv dir/b e" |
1521 $ hg ci -m "mv dir/b e" |
1553 > testlog 'a*'; |
1554 > testlog 'a*'; |
1554 > else |
1555 > else |
1555 > testlog a*; |
1556 > testlog a*; |
1556 > fi; |
1557 > fi; |
1557 ('group', ('group', ('func', ('symbol', 'filelog'), ('string', 'aa')))) |
1558 ('group', ('group', ('func', ('symbol', 'filelog'), ('string', 'aa')))) |
1559 |
|
1560 Test --follow on a directory |
|
1561 |
|
1562 $ testlog -f dir |
|
1563 abort: cannot follow file not in parent revision: "dir" |
|
1564 abort: cannot follow file not in parent revision: "dir" |
|
1565 abort: cannot follow file not in parent revision: "dir" |
|
1566 |
|
1567 Test --follow on file not in parent revision |
|
1568 |
|
1569 $ testlog -f a |
|
1570 abort: cannot follow file not in parent revision: "a" |
|
1571 abort: cannot follow file not in parent revision: "a" |
|
1572 abort: cannot follow file not in parent revision: "a" |
|
1573 |
|
1574 Test --follow and patterns |
|
1575 |
|
1576 $ testlog -f 'glob:*' |
|
1577 abort: can only follow copies/renames for explicit filenames |
|
1578 abort: can only follow copies/renames for explicit filenames |
|
1579 abort: can only follow copies/renames for explicit filenames |
|
1580 |
|
1581 Test --follow on a single rename |
|
1582 |
|
1583 $ hg up -q 2 |
|
1584 $ testlog -f a |
|
1585 ('group', ('group', ('func', ('symbol', 'follow'), ('string', 'a')))) |
|
1586 |
|
1587 Test --follow and multiple renames |
|
1588 |
|
1589 $ hg up -q tip |
|
1590 $ testlog -f e |
|
1591 ('group', ('group', ('func', ('symbol', 'follow'), ('string', 'e')))) |
|
1592 |
|
1593 Test --follow and multiple filelog heads |
|
1594 |
|
1595 $ hg up -q 2 |
|
1596 $ testlog -f g |
|
1597 ('group', ('group', ('func', ('symbol', 'follow'), ('string', 'g')))) |
|
1598 $ cat log.nodes |
|
1599 nodetag 2 |
|
1600 nodetag 1 |
|
1601 nodetag 0 |
|
1602 $ hg up -q tip |
|
1603 $ testlog -f g |
|
1604 ('group', ('group', ('func', ('symbol', 'follow'), ('string', 'g')))) |
|
1605 $ cat log.nodes |
|
1606 nodetag 3 |
|
1607 nodetag 2 |
|
1608 nodetag 0 |
|
1609 |
|
1610 Test --follow and multiple files |
|
1611 |
|
1612 $ testlog -f g e |
|
1613 ('group', ('group', ('or', ('func', ('symbol', 'follow'), ('string', 'g')), ('func', ('symbol', 'follow'), ('string', 'e'))))) |
|
1614 $ cat log.nodes |
|
1615 nodetag 4 |
|
1616 nodetag 3 |
|
1617 nodetag 2 |
|
1618 nodetag 1 |
|
1619 nodetag 0 |
|
1620 |