Show More
@@ -8,7 +8,7 b' To set the pager that should be used, se' | |||
|
8 | 8 | |
|
9 | 9 | If no pager is set, the pager extensions uses the environment variable |
|
10 | 10 | $PAGER. If neither pager.pager, nor $PAGER is set, a default pager |
|
11 | will be used, typically `more`. | |
|
11 | will be used, typically `less` on Unix and `more` on Windows. | |
|
12 | 12 | |
|
13 | 13 | You can disable the pager for certain commands by adding them to the |
|
14 | 14 | pager.ignore list:: |
@@ -21,6 +21,7 b" if pycompat.osname == 'nt':" | |||
|
21 | 21 | else: |
|
22 | 22 | from . import scmposix as scmplatform |
|
23 | 23 | |
|
24 | fallbackpager = scmplatform.fallbackpager | |
|
24 | 25 | systemrcpath = scmplatform.systemrcpath |
|
25 | 26 | userrcpath = scmplatform.userrcpath |
|
26 | 27 |
@@ -12,6 +12,12 b' from . import (' | |||
|
12 | 12 | pycompat, |
|
13 | 13 | ) |
|
14 | 14 | |
|
15 | # BSD 'more' escapes ANSI color sequences by default. This can be disabled by | |
|
16 | # $MORE variable, but there's no compatible option with Linux 'more'. Given | |
|
17 | # OS X is widely used and most modern Unix systems would have 'less', setting | |
|
18 | # 'less' as the default seems reasonable. | |
|
19 | fallbackpager = 'less' | |
|
20 | ||
|
15 | 21 | def _rcfiles(path): |
|
16 | 22 | rcs = [os.path.join(path, 'hgrc')] |
|
17 | 23 | rcdir = os.path.join(path, 'hgrc.d') |
@@ -16,6 +16,9 b' try:' | |||
|
16 | 16 | except ImportError: |
|
17 | 17 | import winreg |
|
18 | 18 | |
|
19 | # MS-DOS 'more' is the only pager available by default on Windows. | |
|
20 | fallbackpager = 'more' | |
|
21 | ||
|
19 | 22 | def systemrcpath(): |
|
20 | 23 | '''return default os-specific hgrc search path''' |
|
21 | 24 | rcpath = [] |
@@ -857,8 +857,7 b' class ui(object):' | |||
|
857 | 857 | # HGPLAINEXCEPT=pager, and the user didn't specify --debug. |
|
858 | 858 | return |
|
859 | 859 | |
|
860 | fallbackpager = 'more' | |
|
861 | pagercmd = self.config('pager', 'pager', fallbackpager) | |
|
860 | pagercmd = self.config('pager', 'pager', rcutil.fallbackpager) | |
|
862 | 861 | if not pagercmd: |
|
863 | 862 | return |
|
864 | 863 |
General Comments 0
You need to be logged in to leave comments.
Login now