INNER CODE UNIT · Python

frontmatter_description

kevinpbuckley/VibeUE · scripts/check_skills_consistency.py:46

def frontmatter_description(text):
    if not text.startswith("---"):
        return None
    close = text.find("\n---", 3)
    if close == -1:
        return None
    for line in text[3:close].splitlines():
        stripped = line.strip()
        if stripped.startswith("description:"):
            return stripped[len("description:"):].strip().strip('"').strip("'")
    return None


def main():
    errors = []

    if not DISPATCHER.is_file():
        print(f"FATAL: dispatcher not found at {DISPATCHER}", file=sys.stderr)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…