MCPcopy Create free account
hub / github.com/defold/defold / _parse_description

Function _parse_description

engine/docs/script_doc.py:263–274  ·  view source on GitHub ↗
(text)

Source from the content-addressed store, hash-verified

261 return "function"
262
263def _parse_description(text):
264 desc_start = min(len(text), text.find('\n'))
265 brief = text[0:desc_start]
266 desc_end = min(len(text), text.find('\n@'))
267 description = text[desc_start:desc_end].strip()
268 if not brief and description:
269 brief = description.split('.\n')[0]
270 if len(brief) > 50: # trial and error of what fits into a single line
271 brief = brief[:50] + '...'
272 elif not description and brief:
273 description = brief
274 return description, brief
275
276def _parse_path(path):
277 file = ""

Callers 1

_parse_commentFunction · 0.70

Calls 3

splitMethod · 0.65
minFunction · 0.50
findMethod · 0.45

Tested by

no test coverage detected