Future proof path permissions for Mercurial 5.0
This commit is contained in:
parent
337f4d617c
commit
f3b08aa126
1 changed files with 8 additions and 4 deletions
|
|
@ -897,11 +897,15 @@ class MercurialRepository(BaseRepository):
|
|||
|
||||
def read_patterns(suffix):
|
||||
svalue = None
|
||||
try:
|
||||
svalue = hgacl.get('narrowhgacl', username + suffix)
|
||||
except configparser.NoOptionError:
|
||||
for section, option in [
|
||||
('narrowacl', username + suffix),
|
||||
('narrowacl', 'default' + suffix),
|
||||
('narrowhgacl', username + suffix),
|
||||
('narrowhgacl', 'default' + suffix)
|
||||
]:
|
||||
try:
|
||||
svalue = hgacl.get('narrowhgacl', 'default' + suffix)
|
||||
svalue = hgacl.get(section, option)
|
||||
break # stop at the first value we find
|
||||
except configparser.NoOptionError:
|
||||
pass
|
||||
if not svalue:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue