MCPcopy Create free account
hub / github.com/codenameone/CodenameOne / parse_meta

Function parse_meta

docs/website/scripts/split_courses.py:32–40  ·  view source on GitHub ↗
(frontmatter: str)

Source from the content-addressed store, hash-verified

30
31
32def parse_meta(frontmatter: str) -> dict:
33 meta = {}
34 for line in frontmatter.splitlines():
35 line = line.strip()
36 if not line or ":" not in line:
37 continue
38 k, v = line.split(":", 1)
39 meta[k.strip()] = v.strip().strip('"')
40 return meta
41
42
43@dataclass

Callers 1

processFunction · 0.85

Calls 2

splitMethod · 0.65
stripMethod · 0.45

Tested by

no test coverage detected