MCPcopy Index your code
hub / github.com/coderoad/coderoad-vscode / getCommitMessage

Function getCommitMessage

src/services/git/index.ts:185–199  ·  view source on GitHub ↗
(hash: string)

Source from the content-addressed store, hash-verified

183}
184
185export async function getCommitMessage(hash: string): Promise<string | null> {
186 try {
187 // returns an list of commit hashes
188 const { stdout, stderr } = await exec({ command: `git log -n 1 --pretty=format:%s ${hash}` })
189 if (stderr) {
190 return null
191 }
192 // string match on remote output
193 return stdout
194 } catch (error: any) {
195 logger(`Error: ${error.message}`)
196 // likely no git commit message found
197 return null
198 }
199}
200
201export async function commitsExistsByMessage(message: string): Promise<boolean> {
202 try {

Callers

nothing calls this directly

Calls 2

execFunction · 0.90
loggerFunction · 0.50

Tested by

no test coverage detected