# HG changeset patch
# User Karl-Dieter Crisman <kcrisman@gmail.com>
# Date 1326208242 18000
# Node ID 4f3101664b49586302a8dd26b03d515311603212
# Parent 85d5104d68b1a43117f055070dbb9ee956ef2dc5
Trac 12288 - reviewer patch to fix HG doctests
diff --git a/sage/misc/hg.py b/sage/misc/hg.py
|
a
|
b
|
|
| 286 | 286 | |
| 287 | 287 | sage: hg_sage.status() |
| 288 | 288 | Getting status of modified or unknown files: |
| 289 | | cd ... && hg status |
| | 289 | cd ... && sage --hg status |
| 290 | 290 | ... |
| 291 | 291 | sage: hg_sage.status(debug=False) |
| 292 | 292 | Getting status of modified or unknown files: |
| … |
… |
|
| 726 | 726 | |
| 727 | 727 | sage: hg_sage.add('module_list.pyc', options='--dry-run') |
| 728 | 728 | Adding file module_list.pyc |
| 729 | | cd ... && hg add --dry-run "module_list.pyc" |
| | 729 | cd ... && sage --hg add --dry-run "module_list.pyc" |
| 730 | 730 | """ |
| 731 | 731 | if isinstance(files, str): |
| 732 | 732 | if ' ' in files: |
| … |
… |
|
| 789 | 789 | |
| 790 | 790 | sage: hg_sage.rename('sage/misc/hg.py', 'sage/misc/hgnew.py', options='--dry-run') |
| 791 | 791 | Moving sage/misc/hg.py --> sage/misc/hgnew.py |
| 792 | | cd ... && hg mv --dry-run "sage/misc/hg.py" "sage/misc/hgnew.py" |
| | 792 | cd ... && sage --hg mv --dry-run "sage/misc/hg.py" "sage/misc/hgnew.py" |
| 793 | 793 | """ |
| 794 | 794 | print "Moving %s --> %s"%(src,dest) |
| 795 | 795 | self('mv %s "%s" "%s"'%(options, src,dest), debug=debug) |
| … |
… |
|
| 999 | 999 | EXAMPLES:: |
| 1000 | 1000 | |
| 1001 | 1001 | sage: hg_sage.revert('sage/misc/hg.py', rev=12000, options='--dry-run') |
| 1002 | | cd ... && hg revert --dry-run -r 12000 sage/misc/hg.py |
| | 1002 | cd ... && sage --hg revert --dry-run -r 12000 sage/misc/hg.py |
| 1003 | 1003 | """ |
| 1004 | 1004 | if not rev is None: |
| 1005 | 1005 | options = options +' -r %s %s'%(rev, files) |
| … |
… |
|
| 1624 | 1624 | EXAMPLES:: |
| 1625 | 1625 | |
| 1626 | 1626 | sage: hg_sage.qseries() |
| 1627 | | cd ... && hg qseries |
| | 1627 | cd ... && sage --hg qseries |
| 1628 | 1628 | """ |
| 1629 | 1629 | options = "--summary" if verbose else "" |
| 1630 | 1630 | self('qseries %s %s' % (options, color(),), debug=debug) |
| … |
… |
|
| 1643 | 1643 | EXAMPLES:: |
| 1644 | 1644 | |
| 1645 | 1645 | sage: hg_sage.qapplied() |
| 1646 | | cd ... && hg qapplied |
| | 1646 | cd ... && sage --hg qapplied |
| 1647 | 1647 | """ |
| 1648 | 1648 | options = "--summary" if verbose else "" |
| 1649 | 1649 | self('qapplied %s %s' % (options, color(),), debug=debug) |
| … |
… |
|
| 1662 | 1662 | EXAMPLES:: |
| 1663 | 1663 | |
| 1664 | 1664 | sage: hg_sage.qunapplied() |
| 1665 | | cd ... && hg qunapplied |
| | 1665 | cd ... && sage --hg qunapplied |
| 1666 | 1666 | """ |
| 1667 | 1667 | options = "--summary" if verbose else "" |
| 1668 | 1668 | self('qunapplied %s %s' % (options, color(),), debug=debug) |