@mastra/core
Version:
Mastra is a framework for building AI-powered applications and agents with a modern TypeScript stack.
18 lines • 757 B
TypeScript
/**
* Gitignore support for workspace tools.
*
* Reads `.gitignore` from the workspace filesystem root and provides
* a filter function that tools can use during directory walking.
*/
import type { WorkspaceFilesystem } from './filesystem/index.js';
export type IgnoreFilter = (relativePath: string) => boolean;
/**
* Load `.gitignore` from the workspace root and return a filter function.
*
* The returned function takes a path relative to the workspace root and
* returns `true` if the path is ignored (should be skipped).
*
* Returns `undefined` if no `.gitignore` exists or it can't be read.
*/
export declare function loadGitignore(filesystem: WorkspaceFilesystem): Promise<IgnoreFilter | undefined>;
//# sourceMappingURL=gitignore.d.ts.map