Document calculation of indentation
Change-Id: I0f107d8239ae0cbef3bb4569ec5d77326f8974fc
This commit is contained in:
parent
7c0c4dd6fd
commit
0d33a2f598
@ -123,6 +123,10 @@ class OverrideConfigParser(iniparser.BaseParser):
|
|||||||
ws=self._whitespace,
|
ws=self._whitespace,
|
||||||
value=value))
|
value=value))
|
||||||
else:
|
else:
|
||||||
|
# We want additional values to be written out under the
|
||||||
|
# first value with the same indentation, like this:
|
||||||
|
# key = value1
|
||||||
|
# value2
|
||||||
indent_size = len(key) + len(self._whitespace) * 2 + 1
|
indent_size = len(key) + len(self._whitespace) * 2 + 1
|
||||||
ws_indent = ' ' * indent_size
|
ws_indent = ' ' * indent_size
|
||||||
fp.write('{ws_indent}{value}\n'.format(
|
fp.write('{ws_indent}{value}\n'.format(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user