Mercurial > hg-stable
comparison mercurial/ui.py @ 38726:d79f3afb079e
curses: use "text" interface if TERM=dumb
Differential Revision: https://phab.mercurial-scm.org/D3948
author | Kyle Lippincott <spectral@google.com> |
---|---|
date | Mon, 16 Jul 2018 11:38:56 -0700 |
parents | bfcd5c7cbf9a |
children | fe3ca1e6f786 |
comparison
equal
deleted
inserted
replaced
38725:c382c19ce9bd | 38726:d79f3afb079e |
---|---|
1212 # define the right thing to do here. | 1212 # define the right thing to do here. |
1213 raise ValueError( | 1213 raise ValueError( |
1214 "Feature %s does not handle all default interfaces" % | 1214 "Feature %s does not handle all default interfaces" % |
1215 feature) | 1215 feature) |
1216 | 1216 |
1217 if self.plain(): | 1217 if self.plain() or encoding.environ.get('TERM') == 'dumb': |
1218 return "text" | 1218 return "text" |
1219 | 1219 |
1220 # Default interface for all the features | 1220 # Default interface for all the features |
1221 defaultinterface = "text" | 1221 defaultinterface = "text" |
1222 i = self.config("ui", "interface") | 1222 i = self.config("ui", "interface") |