Mercurial > hgrepos > Python > libs > ConfigMix
diff configmix/config.py @ 459:9dc9cef1b9cd
Implement proper iteration support for jailed configurations
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Wed, 15 Dec 2021 08:48:37 +0100 |
| parents | 27112bb4a5b9 |
| children | d22985d6806e |
line wrap: on
line diff
--- a/configmix/config.py Wed Dec 15 01:01:07 2021 +0100 +++ b/configmix/config.py Wed Dec 15 08:48:37 2021 +0100 @@ -940,6 +940,9 @@ real_varnames = [self._pathstr + vn for vn in varnames] return self._base.getfirstvar_s(*real_varnames, **kwds) + def __iter__(self): + return iter(self._base.getvarl_s(*self._path)) + def jailed(self, rootpath=None, root=None, bind_root=True): """Return a "jailed" configuration that effectively is a subjail of the current jail
