mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 15:27:13 +03:00
pager: skip running the pager if it's set to 'cat'
Avoid useless uses of cat.
This commit is contained in:
parent
dd0af0f250
commit
3839a3e429
@ -935,6 +935,9 @@ class ui(object):
|
||||
This is separate in part so that extensions (like chg) can
|
||||
override how a pager is invoked.
|
||||
"""
|
||||
if command == 'cat':
|
||||
# Save ourselves some work.
|
||||
return
|
||||
# If the command doesn't contain any of these characters, we
|
||||
# assume it's a binary and exec it directly. This means for
|
||||
# simple pager command configurations, we can degrade
|
||||
|
Loading…
Reference in New Issue
Block a user