diff options
author | Jan Pokorný <jpokorny@redhat.com> | 2014-11-24 22:36:30 +0100 |
---|---|---|
committer | Jan Pokorný <jpokorny@redhat.com> | 2014-11-24 22:45:58 +0100 |
commit | 84d0e6b8bab10abd3f06db8b6f13967f5a809366 (patch) | |
tree | d004fe50c14b179396e7378ee3908bfba47383cb /formats | |
parent | c4344cb22c4e52dfed2d955a3d69411b849f18ef (diff) | |
download | clufter-84d0e6b8bab10abd3f06db8b6f13967f5a809366.tar.gz clufter-84d0e6b8bab10abd3f06db8b6f13967f5a809366.tar.xz clufter-84d0e6b8bab10abd3f06db8b6f13967f5a809366.zip |
formats/simpleconfig: allow env override for indentation
Signed-off-by: Jan Pokorný <jpokorny@redhat.com>
Diffstat (limited to 'formats')
-rw-r--r-- | formats/simpleconfig.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/formats/simpleconfig.py b/formats/simpleconfig.py index 04df34b..756ab93 100644 --- a/formats/simpleconfig.py +++ b/formats/simpleconfig.py @@ -9,6 +9,7 @@ from ..format import SimpleFormat from ..protocol import Protocol from ..utils import tuplist from ..utils_func import apply_aggregation_preserving_depth +from ..utils_prog import getenv_namespaced class simpleconfig(SimpleFormat): @@ -77,7 +78,7 @@ class simpleconfig(SimpleFormat): # fallback struct = self.STRUCT(protect_safe=True) - indent, optindent = ('\t', ) * 2 + indent, optindent = (getenv_namespaced('COROINDENT', '\t'), ) * 2 lbrace, rbrace, optsep = '{', '}', ': ' # XXX previous apply_aggregation_preserving_passing_depth attempt # was unsuccessful |