MCPcopy Create free account
hub / github.com/Zoo-Code-Org/Zoo-Code / truncateLine

Function truncateLine

src/services/ripgrep/index.ts:84–86  ·  view source on GitHub ↗
(line: string, maxLength: number = MAX_LINE_LENGTH)

Source from the content-addressed store, hash-verified

82 * @returns The truncated line, or the original line if it's shorter than maxLength
83 */
84export function truncateLine(line: string, maxLength: number = MAX_LINE_LENGTH): string {
85 return line.length > maxLength ? line.substring(0, maxLength) + " [truncated...]" : line
86}
87/**
88 * Returns the ordered list of absolute candidate paths where ripgrep may
89 * live under the given VS Code appRoot. Used by both getBinPath (first-match

Callers 2

index.spec.tsFile · 0.90
regexSearchFilesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected