mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 13:19:24 +01:00
Output the default value into the registry file.
This commit is contained in:
parent
a15b87cd1a
commit
b8b014d447
@ -87,6 +87,13 @@ def close(registry, filename, annotated=True):
|
|||||||
first = False
|
first = False
|
||||||
else:
|
else:
|
||||||
lines.insert(0, '\n')
|
lines.insert(0, '\n')
|
||||||
|
lines.append('#\n')
|
||||||
|
try:
|
||||||
|
original = value.value
|
||||||
|
value.value = value.default
|
||||||
|
lines.append('# Default value: %s\n' % value)
|
||||||
|
finally:
|
||||||
|
value.value = original
|
||||||
lines.append('###\n')
|
lines.append('###\n')
|
||||||
fd.writelines(lines)
|
fd.writelines(lines)
|
||||||
fd.write('%s: %s\n' % (name, value))
|
fd.write('%s: %s\n' % (name, value))
|
||||||
|
Loading…
Reference in New Issue
Block a user