MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / getFileByPath

Method getFileByPath

src/db/queries.ts:2161–2167  ·  view source on GitHub ↗

* Get a file record by path

(filePath: string)

Source from the content-addressed store, hash-verified

2159 * Get a file record by path
2160 */
2161 getFileByPath(filePath: string): FileRecord | null {
2162 if (!this.stmts.getFileByPath) {
2163 this.stmts.getFileByPath = this.db.prepare('SELECT * FROM files WHERE path = ?');
2164 }
2165 const row = this.stmts.getFileByPath.get(filePath) as FileRow | undefined;
2166 return row ? rowToFileRecord(row) : null;
2167 }
2168
2169 /**
2170 * Get all tracked files

Callers 6

getFileMethod · 0.80
indexFilesMethod · 0.80
storeExtractionResultMethod · 0.80
syncMethod · 0.80
getChangedFilesMethod · 0.80
security.test.tsFile · 0.80

Calls 3

rowToFileRecordFunction · 0.85
prepareMethod · 0.65
getMethod · 0.65

Tested by

no test coverage detected