pub fn extract(plan: &str, task: &str) -> Option<String>Expand description
The section of plan whose heading matches task, including the heading line, up to (not
including) the next heading of the same or a higher level (fewer or equal #), or the end.
A heading matches when its text after the #s, trimmed, equals task trimmed, or starts with
task followed by :, -, — or (. Example: task “Task B2” matches
“### Task B2: the parser” and “### Task B2”, but not “### Task B20”.
Headings inside fenced code blocks (``` or ~~~) are ignored.
Returns None if no heading matches; if several match, the first.