(s: string)
| 127 | * could otherwise return arbitrary content that flows into shell contexts. |
| 128 | */ |
| 129 | export function isValidGitSha(s: string): boolean { |
| 130 | return /^[0-9a-f]{40}$/.test(s) || /^[0-9a-f]{64}$/.test(s) |
| 131 | } |
| 132 | |
| 133 | // --------------------------------------------------------------------------- |
| 134 | // readGitHead — parse .git/HEAD |
no outgoing calls
no test coverage detected