# HG changeset patch
# User J. H. Palmieri <palmieri@math.washington.edu>
# Date 1326148179 28800
# Node ID 560ebfe0044c3ea63f17973330d78c7ad23806a4
# Parent 92c93226b64f933e0af00bbcbd1a8a79c444f43f
#12288: use "sage --hg" instead of "hg" to run Mercurial from within Sage.
diff --git a/sage/misc/hg.py b/sage/misc/hg.py
|
a
|
b
|
class HG: |
| 386 | 386 | self._warning() |
| 387 | 387 | if cmd is None: |
| 388 | 388 | cmd = 'status' |
| 389 | | s = 'cd "%s" && hg %s'%(self.__dir, cmd) |
| | 389 | # Invoke Mercurial with "sage --hg", not just "hg": when |
| | 390 | # calling "hg", the variable HGPLAIN is set (by sage-env), |
| | 391 | # which disables various configuration options, like the use |
| | 392 | # of a pager. When calling "sage --hg", HGPLAIN is explicitly |
| | 393 | # unset (see the script sage-sage), so the pager will be used, |
| | 394 | # as will color output, etc. See trac ticket #12288. |
| | 395 | s = 'cd "%s" && sage --hg %s'%(self.__dir, cmd) |
| 390 | 396 | if debug: |
| 391 | 397 | print s |
| 392 | 398 | if interactive: |