(h: CommitHeader, github_url: str)
| 80 | |
| 81 | |
| 82 | def convert_header(h: CommitHeader, github_url: str) -> ghstack.diff.Diff: |
| 83 | return ghstack.diff.Diff( |
| 84 | title=h.title, |
| 85 | summary=h.commit_msg, |
| 86 | oid=h.commit_id, |
| 87 | source_id=h.tree, |
| 88 | pull_request_resolved=ghstack.diff.PullRequestResolved.search( |
| 89 | h.raw_header, github_url |
| 90 | ), |
| 91 | tree=h.tree, |
| 92 | author_name=h.author_name, |
| 93 | author_email=h.author_email, |
| 94 | boundary=h.boundary, |
| 95 | ) |
| 96 | |
| 97 | |
| 98 | def parse_header(s: str, github_url: str) -> List[ghstack.diff.Diff]: |