MCPcopy Index your code
hub / github.com/github/awesome-copilot / statusFromText

Function statusFromText

extensions/java-modernization-studio/scan.mjs:151–157  ·  view source on GitHub ↗
(text)

Source from the content-addressed store, hash-verified

149
150// Infer a status from inline markers / emojis in a line of text.
151function statusFromText(text) {
152 const t = text.toLowerCase();
153 if (/[✅✔]|\bdone\b|\bcompleted?\b|\bpassed?\b/.test(t)) return "done";
154 if (/[❌✖]|\bfailed?\b|\berror\b|\bblocked\b/.test(t)) return "failed";
155 if (/[⏳🔄]|in progress|in-progress|ongoing|running|wip/.test(t)) return "in_progress";
156 return null;
157}
158
159// Parse GitHub-style task list items: "- [ ] ...", "- [x] ...", "- [/] ...".
160// Each item also carries the nearest preceding heading as its `section`.

Callers 3

parseChecklistFunction · 0.85
parseLooseStepsFunction · 0.85
deriveGatesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected