MCPcopy Create free account
hub / github.com/mikro-orm/mikro-orm / globSync

Function globSync

packages/core/src/utils/fs-utils.ts:11–14  ·  view source on GitHub ↗
(patterns, options)

Source from the content-addressed store, hash-verified

9type GlobFn = (patterns: string | string[], options?: { cwd?: string; expandDirectories?: boolean }) => string[];
10
11let globSync: GlobFn = (patterns, options) => {
12 const files = nodeGlobSync(patterns, { ...options, withFileTypes: true });
13 return files.filter(f => f.isFile()).map(f => join(f.parentPath, f.name));
14};
15
16export interface FsUtils {
17 init(): Promise<void>;

Callers 2

pathExistsFunction · 0.85
resolveGlobFunction · 0.85

Calls 2

filterMethod · 0.80
mapMethod · 0.45

Tested by

no test coverage detected