(message)
| 67 | return out.split(/\r?\n/).filter(Boolean); |
| 68 | } |
| 69 | function parseCoAuthorLines(message) { |
| 70 | const out = []; |
| 71 | const re = /^[ \t]*Co-authored-by:\s*(.+?)\s*<([^>]+)>/gim; |
| 72 | let m; |
| 73 | while ((m = re.exec(message))) out.push({ name: m[1].trim(), email: m[2].trim() }); |
| 74 | return out; |
| 75 | } |
| 76 | function loginFromNoreply(email) { |
| 77 | const m = email.toLowerCase().match(/^(?:\d+\+)?([a-z0-9-]+)@users\.noreply\.github\.com$/i); |
| 78 | return m ? m[1] : ""; |