2 Commits

Author SHA1 Message Date
a7f470c837 0.2 2019-07-29 22:07:46 +02:00
76d63eb707 add description function 2019-07-29 22:06:04 +02:00
3 changed files with 7 additions and 1 deletions

View File

View File

@ -1,5 +1,5 @@
from .api import Config from .api import Config
__version__ = "0.1" __version__ = "0.2"
__all__ = ('Config',) __all__ = ('Config',)

View File

@ -75,6 +75,12 @@ class TiramisuOptionOption:
self.schema = schema self.schema = schema
def doc(self): def doc(self):
description = self.description()
if not description:
return self.name()
return description
def description(self):
if self.issymlinkoption(): if self.issymlinkoption():
schema = self.config.get_schema(self.schema['opt_path']) schema = self.config.get_schema(self.schema['opt_path'])
else: else: