MCPcopy Index your code
hub / github.com/codeaashu/claude-code / getFileMtime

Function getFileMtime

src/utils/commitAttribution.ts:387–396  ·  view source on GitHub ↗
(filePath: string)

Source from the content-addressed store, hash-verified

385 * entering a sync setAppState callback.
386 */
387export async function getFileMtime(filePath: string): Promise<number> {
388 const normalizedPath = normalizeFilePath(filePath)
389 const absPath = expandFilePath(normalizedPath)
390 try {
391 const stats = await stat(absPath)
392 return stats.mtimeMs
393 } catch {
394 return Date.now()
395 }
396}
397
398/**
399 * Track a file modification by Claude.

Callers

nothing calls this directly

Calls 3

normalizeFilePathFunction · 0.85
expandFilePathFunction · 0.85
statFunction · 0.85

Tested by

no test coverage detected