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

Function readFileLines

src/utils/shellConfig.ts:81–91  ·  view source on GitHub ↗
(
  filePath: string,
)

Source from the content-addressed store, hash-verified

79 * Returns null if file doesn't exist or can't be read
80 */
81export async function readFileLines(
82 filePath: string,
83): Promise<string[] | null> {
84 try {
85 const content = await readFile(filePath, { encoding: 'utf8' })
86 return content.split('\n')
87 } catch (e: unknown) {
88 if (isFsInaccessible(e)) return null
89 throw e
90 }
91}
92
93/**
94 * Write lines back to a file

Callers 3

findClaudeAliasFunction · 0.85
cleanupShellAliasesFunction · 0.85

Calls 2

readFileFunction · 0.85
isFsInaccessibleFunction · 0.85

Tested by

no test coverage detected