config: read system hgrc in lexicographical order
This is similar to edbcf5b239f9 (config: read configs from directories
in lexicographical order, 2019-04-03). Apparently I forgot to sort the
system hgrc files there. That's fixed by this patch.
Differential Revision: https://phab.mercurial-scm.org/D9269
--- a/mercurial/scmposix.py Sun Nov 08 20:12:32 2020 +0100
+++ b/mercurial/scmposix.py Tue Nov 03 09:56:02 2020 -0800
@@ -27,7 +27,7 @@
rcs.extend(
[
os.path.join(rcdir, f)
- for f, kind in util.listdir(rcdir)
+ for f, kind in sorted(util.listdir(rcdir))
if f.endswith(b".rc")
]
)
--- a/mercurial/scmwindows.py Sun Nov 08 20:12:32 2020 +0100
+++ b/mercurial/scmwindows.py Tue Nov 03 09:56:02 2020 -0800
@@ -31,7 +31,7 @@
def _processdir(progrcd):
if os.path.isdir(progrcd):
- for f, kind in util.listdir(progrcd):
+ for f, kind in sorted(util.listdir(progrcd)):
if f.endswith(b'.rc'):
rcpath.append(os.path.join(progrcd, f))