# HG changeset patch # User Yuya Nishihara # Date 2010-05-16 13:23:14 # Node ID b25464e9b4481eb4e24fea0e73267fd26546bfc7 # Parent 6e65b451b62e6b5bf57e5df34e56214c78e762d6 patchbomb: respect HGPLAIN when piping --test output to PAGER It makes easy to use `hg email --test` from another tool. diff --git a/hgext/patchbomb.py b/hgext/patchbomb.py --- a/hgext/patchbomb.py +++ b/hgext/patchbomb.py @@ -450,7 +450,7 @@ def patchbomb(ui, repo, *revs, **opts): if opts.get('test'): ui.status(_('Displaying '), subj, ' ...\n') ui.flush() - if 'PAGER' in os.environ: + if 'PAGER' in os.environ and not ui.plain(): fp = util.popen(os.environ['PAGER'], 'w') else: fp = ui