(value: string)
| 34 | import type { ContentReplacementRecord } from '../utils/toolResultStorage.js'; |
| 35 | import { REPL } from './REPL.js'; |
| 36 | function parsePrIdentifier(value: string): number | null { |
| 37 | const directNumber = parseInt(value, 10); |
| 38 | if (!isNaN(directNumber) && directNumber > 0) { |
| 39 | return directNumber; |
| 40 | } |
| 41 | const urlMatch = value.match(/github\.com\/[^/]+\/[^/]+\/pull\/(\d+)/); |
| 42 | if (urlMatch?.[1]) { |
| 43 | return parseInt(urlMatch[1], 10); |
| 44 | } |
| 45 | return null; |
| 46 | } |
| 47 | type Props = { |
| 48 | commands: Command[]; |
| 49 | worktreePaths: string[]; |
no outgoing calls
no test coverage detected