main
  1// Generated by dts-bundle-generator v9.5.1
  2
  3/// <reference types="node" />
  4
  5import * as fs from 'fs';
  6import { URL as URL$1 } from 'node:url';
  7
  8declare type ErrnoException = NodeJS.ErrnoException;
  9declare type StatAsynchronousMethod = (path: string, callback: (error: ErrnoException | null, stats: fs.Stats) => void) => void;
 10declare type StatSynchronousMethod = (path: string) => fs.Stats;
 11interface FileSystemAdapter {
 12	lstat: StatAsynchronousMethod;
 13	stat: StatAsynchronousMethod;
 14	lstatSync: StatSynchronousMethod;
 15	statSync: StatSynchronousMethod;
 16}
 17interface Entry {
 18	dirent: Dirent;
 19	name: string;
 20	path: string;
 21	stats?: Stats;
 22}
 23declare type Stats = fs.Stats;
 24declare type ErrnoException$1 = NodeJS.ErrnoException;
 25interface Dirent {
 26	isBlockDevice: () => boolean;
 27	isCharacterDevice: () => boolean;
 28	isDirectory: () => boolean;
 29	isFIFO: () => boolean;
 30	isFile: () => boolean;
 31	isSocket: () => boolean;
 32	isSymbolicLink: () => boolean;
 33	name: string;
 34}
 35interface ReaddirAsynchronousMethod {
 36	(filepath: string, options: {
 37		withFileTypes: true;
 38	}, callback: (error: ErrnoException$1 | null, files: Dirent[]) => void): void;
 39	(filepath: string, callback: (error: ErrnoException$1 | null, files: string[]) => void): void;
 40}
 41interface ReaddirSynchronousMethod {
 42	(filepath: string, options: {
 43		withFileTypes: true;
 44	}): Dirent[];
 45	(filepath: string): string[];
 46}
 47declare type FileSystemAdapter$1 = FileSystemAdapter & {
 48	readdir: ReaddirAsynchronousMethod;
 49	readdirSync: ReaddirSynchronousMethod;
 50};
 51declare type Entry$1 = Entry;
 52type Entry$2 = Entry$1;
 53type Pattern = string;
 54type FileSystemAdapter$2 = FileSystemAdapter$1;
 55type Options = {
 56	/**
 57	 * Return the absolute path for entries.
 58	 *
 59	 * @default false
 60	 */
 61	absolute?: boolean;
 62	/**
 63	 * If set to `true`, then patterns without slashes will be matched against
 64	 * the basename of the path if it contains slashes.
 65	 *
 66	 * @default false
 67	 */
 68	baseNameMatch?: boolean;
 69	/**
 70	 * Enables Bash-like brace expansion.
 71	 *
 72	 * @default true
 73	 */
 74	braceExpansion?: boolean;
 75	/**
 76	 * Enables a case-sensitive mode for matching files.
 77	 *
 78	 * @default true
 79	 */
 80	caseSensitiveMatch?: boolean;
 81	/**
 82	 * Specifies the maximum number of concurrent requests from a reader to read
 83	 * directories.
 84	 *
 85	 * @default os.cpus().length
 86	 */
 87	concurrency?: number;
 88	/**
 89	 * The current working directory in which to search.
 90	 *
 91	 * @default process.cwd()
 92	 */
 93	cwd?: string;
 94	/**
 95	 * Specifies the maximum depth of a read directory relative to the start
 96	 * directory.
 97	 *
 98	 * @default Infinity
 99	 */
100	deep?: number;
101	/**
102	 * Allow patterns to match entries that begin with a period (`.`).
103	 *
104	 * @default false
105	 */
106	dot?: boolean;
107	/**
108	 * Enables Bash-like `extglob` functionality.
109	 *
110	 * @default true
111	 */
112	extglob?: boolean;
113	/**
114	 * Indicates whether to traverse descendants of symbolic link directories.
115	 *
116	 * @default true
117	 */
118	followSymbolicLinks?: boolean;
119	/**
120	 * Custom implementation of methods for working with the file system.
121	 *
122	 * @default fs.*
123	 */
124	fs?: Partial<FileSystemAdapter$2>;
125	/**
126	 * Enables recursively repeats a pattern containing `**`.
127	 * If `false`, `**` behaves exactly like `*`.
128	 *
129	 * @default true
130	 */
131	globstar?: boolean;
132	/**
133	 * An array of glob patterns to exclude matches.
134	 * This is an alternative way to use negative patterns.
135	 *
136	 * @default []
137	 */
138	ignore?: Pattern[];
139	/**
140	 * Mark the directory path with the final slash.
141	 *
142	 * @default false
143	 */
144	markDirectories?: boolean;
145	/**
146	 * Returns objects (instead of strings) describing entries.
147	 *
148	 * @default false
149	 */
150	objectMode?: boolean;
151	/**
152	 * Return only directories.
153	 *
154	 * @default false
155	 */
156	onlyDirectories?: boolean;
157	/**
158	 * Return only files.
159	 *
160	 * @default true
161	 */
162	onlyFiles?: boolean;
163	/**
164	 * Enables an object mode (`objectMode`) with an additional `stats` field.
165	 *
166	 * @default false
167	 */
168	stats?: boolean;
169	/**
170	 * By default this package suppress only `ENOENT` errors.
171	 * Set to `true` to suppress any error.
172	 *
173	 * @default false
174	 */
175	suppressErrors?: boolean;
176	/**
177	 * Throw an error when symbolic link is broken if `true` or safely
178	 * return `lstat` call if `false`.
179	 *
180	 * @default false
181	 */
182	throwErrorOnBrokenSymbolicLink?: boolean;
183	/**
184	 * Ensures that the returned entries are unique.
185	 *
186	 * @default true
187	 */
188	unique?: boolean;
189};
190type Task = {
191	base: string;
192	dynamic: boolean;
193	patterns: Pattern[];
194	positive: Pattern[];
195	negative: Pattern[];
196};
197type EntryObjectModePredicate = {
198	[TKey in keyof Pick<Options, "objectMode">]-?: true;
199};
200type EntryStatsPredicate = {
201	[TKey in keyof Pick<Options, "stats">]-?: true;
202};
203type EntryObjectPredicate = EntryObjectModePredicate | EntryStatsPredicate;
204declare function FastGlob(source: Pattern | Pattern[], options: Options & EntryObjectPredicate): Promise<Entry$2[]>;
205declare function FastGlob(source: Pattern | Pattern[], options?: Options): Promise<string[]>;
206declare namespace FastGlob {
207	export {Options};
208	export type Entry = Entry$2;
209	export {Task};
210	export {Pattern};
211	type FileSystemAdapter = FileSystemAdapter$2;
212	const glob: typeof FastGlob;
213	const globSync: typeof sync;
214	const globStream: typeof stream;
215	const async: typeof FastGlob;
216	function sync(source: Pattern | Pattern[], options: Options & EntryObjectPredicate): Entry$2[];
217	function sync(source: Pattern | Pattern[], options?: Options): string[];
218	function stream(source: Pattern | Pattern[], options?: Options): NodeJS.ReadableStream;
219	function generateTasks(source: Pattern | Pattern[], options?: Options): Task[];
220	function isDynamicPattern(source: Pattern, options?: Options): boolean;
221	function escapePath(source: string): Pattern;
222	function convertPathToPattern(source: string): Pattern;
223	namespace posix {
224		function escapePath(source: string): Pattern;
225		function convertPathToPattern(source: string): Pattern;
226	}
227	namespace win32 {
228		function escapePath(source: string): Pattern;
229		function convertPathToPattern(source: string): Pattern;
230	}
231}
232type GlobEntry = FastGlob.Entry;
233type GlobTask = {
234	readonly patterns: string[];
235	readonly options: Options$1;
236};
237type ExpandDirectoriesOption = boolean | readonly string[] | {
238	files?: readonly string[];
239	extensions?: readonly string[];
240};
241type FastGlobOptionsWithoutCwd = Omit<FastGlob.Options, "cwd">;
242type Options$1 = {
243	/**
244	If set to `true`, `globby` will automatically glob directories for you. If you define an `Array` it will only glob files that matches the patterns inside the `Array`. You can also define an `Object` with `files` and `extensions` like in the example below.
245
246	Note that if you set this option to `false`, you won't get back matched directories unless you set `onlyFiles: false`.
247
248	@default true
249
250	@example
251	```
252	import {globby} from 'globby';
253
254	const paths = await globby('images', {
255		expandDirectories: {
256			files: ['cat', 'unicorn', '*.jpg'],
257			extensions: ['png']
258		}
259	});
260
261	console.log(paths);
262	//=> ['cat.png', 'unicorn.png', 'cow.jpg', 'rainbow.jpg']
263	```
264	*/
265	readonly expandDirectories?: ExpandDirectoriesOption;
266	/**
267	Respect ignore patterns in `.gitignore` files that apply to the globbed files.
268
269	When enabled, globby searches for `.gitignore` files from the current working directory downward, and if a Git repository is detected (by finding a `.git` directory), it also respects `.gitignore` files in parent directories up to the repository root. This matches Git's actual behavior where patterns from parent `.gitignore` files apply to subdirectories.
270
271	Gitignore patterns take priority over user patterns, matching Git's behavior. To include gitignored files, set this to `false`.
272
273	Performance: Globby reads `.gitignore` files before globbing. When there are no negation patterns (like `!important.log`) and no parent `.gitignore` files are found, it passes ignore patterns to fast-glob to skip traversing ignored directories entirely, which significantly improves performance for large `node_modules` or build directories. When negation patterns or parent `.gitignore` files are present, all filtering is done after traversal to ensure correct Git-compatible behavior. For optimal performance, prefer specific `.gitignore` patterns without negations, or use `ignoreFiles: '.gitignore'` to target only the root ignore file.
274
275	@default false
276	*/
277	readonly gitignore?: boolean;
278	/**
279	Glob patterns to look for ignore files, which are then used to ignore globbed files.
280
281	This is a more generic form of the `gitignore` option, allowing you to find ignore files with a [compatible syntax](http://git-scm.com/docs/gitignore). For instance, this works with Babel's `.babelignore`, Prettier's `.prettierignore`, or ESLint's `.eslintignore` files.
282
283	Performance tip: Using a specific path like `'.gitignore'` is much faster than recursive patterns.
284
285	@default undefined
286	*/
287	readonly ignoreFiles?: string | readonly string[];
288	/**
289	The current working directory in which to search.
290
291	@default process.cwd()
292	*/
293	readonly cwd?: URL | string;
294} & FastGlobOptionsWithoutCwd;
295type GitignoreOptions = {
296	/**
297	The current working directory in which to search.
298
299	@default process.cwd()
300	*/
301	readonly cwd?: URL | string;
302	/**
303	Suppress errors when encountering directories or files without read permissions.
304
305	By default, fast-glob only suppresses `ENOENT` errors. Set to `true` to suppress any error.
306
307	@default false
308	*/
309	readonly suppressErrors?: boolean;
310	/**
311	Specifies the maximum depth of ignore file search relative to the start directory.
312
313	@default Infinity
314	*/
315	readonly deep?: number;
316	/**
317	Glob patterns to exclude from ignore file search.
318
319	@default []
320	*/
321	readonly ignore?: string | readonly string[];
322	/**
323	Indicates whether to traverse descendants of symbolic link directories.
324
325	@default true
326	*/
327	readonly followSymbolicLinks?: boolean;
328	/**
329	Specifies the maximum number of concurrent requests from a reader to read directories.
330
331	@default os.cpus().length
332	*/
333	readonly concurrency?: number;
334	/**
335	Throw an error when symbolic link is broken if `true` or safely return `lstat` call if `false`.
336
337	@default false
338	*/
339	readonly throwErrorOnBrokenSymbolicLink?: boolean;
340	/**
341	Custom file system implementation (useful for testing or virtual file systems).
342
343	@default undefined
344	*/
345	readonly fs?: FastGlob.Options["fs"];
346};
347type GlobbyFilterFunction = (path: URL | string) => boolean;
348type AsyncIterableReadable<Value> = Omit<NodeJS.ReadableStream, typeof Symbol.asyncIterator> & {
349	[Symbol.asyncIterator](): NodeJS.AsyncIterator<Value>;
350};
351type GlobbyStream = AsyncIterableReadable<string>;
352type GlobbyEntryStream = AsyncIterableReadable<GlobEntry>;
353declare function globby(patterns: string | readonly string[], options: Options$1 & ({
354	objectMode: true;
355} | {
356	stats: true;
357})): Promise<GlobEntry[]>;
358declare function globby(patterns: string | readonly string[], options?: Options$1): Promise<string[]>;
359declare function globbySync(patterns: string | readonly string[], options: Options$1 & ({
360	objectMode: true;
361} | {
362	stats: true;
363})): GlobEntry[];
364declare function globbySync(patterns: string | readonly string[], options?: Options$1): string[];
365declare function globbyStream(patterns: string | readonly string[], options: Options$1 & ({
366	objectMode: true;
367} | {
368	stats: true;
369})): GlobbyEntryStream;
370declare function globbyStream(patterns: string | readonly string[], options?: Options$1): GlobbyStream;
371declare function generateGlobTasks(patterns: string | readonly string[], options?: Options$1): Promise<GlobTask[]>;
372declare function generateGlobTasksSync(patterns: string | readonly string[], options?: Options$1): GlobTask[];
373declare function isDynamicPattern(patterns: string | readonly string[], options?: FastGlobOptionsWithoutCwd & {
374	/**
375	The current working directory in which to search.
376
377	@default process.cwd()
378	*/
379	readonly cwd?: URL | string;
380}): boolean;
381declare function isGitIgnored(options?: GitignoreOptions): Promise<GlobbyFilterFunction>;
382declare function isGitIgnoredSync(options?: GitignoreOptions): GlobbyFilterFunction;
383declare function convertPathToPattern(source: string): FastGlob.Pattern;
384declare function parse(source: string): any;
385declare function stringify(value: any): string;
386declare const fetch$1: typeof globalThis.fetch;
387type TCodeRef = {
388	type: string;
389	value: string;
390	index: number;
391};
392type TOptsNormalized = {
393	comments: boolean;
394	bufferSize: number;
395	re: RegExp;
396	offset: number;
397};
398type TOpts = Partial<TOptsNormalized>;
399declare const depseekSync: (input: string | Buffer, opts?: TOpts) => TCodeRef[];
400declare function minimist(args?: string[], opts?: minimist.Opts): minimist.ParsedArgs;
401declare function minimist<T>(args?: string[], opts?: minimist.Opts): T & minimist.ParsedArgs;
402declare function minimist<T extends minimist.ParsedArgs>(args?: string[], opts?: minimist.Opts): T;
403declare namespace minimist {
404	interface Opts {
405		/**
406		 * A string or array of strings argument names to always treat as strings
407		 */
408		string?: string | string[] | undefined;
409		/**
410		 * A boolean, string or array of strings to always treat as booleans. If true will treat
411		 * all double hyphenated arguments without equals signs as boolean (e.g. affects `--foo`, not `-f` or `--foo=bar`)
412		 */
413		boolean?: boolean | string | string[] | undefined;
414		/**
415		 * An object mapping string names to strings or arrays of string argument names to use as aliases
416		 */
417		alias?: {
418			[key: string]: string | string[];
419		} | undefined;
420		/**
421		 * An object mapping string argument names to default values
422		 */
423		default?: {
424			[key: string]: any;
425		} | undefined;
426		/**
427		 * When true, populate argv._ with everything after the first non-option
428		 */
429		stopEarly?: boolean | undefined;
430		/**
431		 * A function which is invoked with a command line parameter not defined in the opts
432		 * configuration object. If the function returns false, the unknown option is not added to argv
433		 */
434		unknown?: ((arg: string) => boolean) | undefined;
435		/**
436		 * When true, populate argv._ with everything before the -- and argv['--'] with everything after the --.
437		 * Note that with -- set, parsing for arguments still stops after the `--`.
438		 */
439		"--"?: boolean | undefined;
440	}
441	interface ParsedArgs {
442		[arg: string]: any;
443		/**
444		 * If opts['--'] is true, populated with everything after the --
445		 */
446		"--"?: string[] | undefined;
447		/**
448		 * Contains all the arguments that didn't have an option associated with them
449		 */
450		_: string[];
451	}
452}
453declare const _default: {
454	parse: (content: string | Buffer) => NodeJS.ProcessEnv;
455	stringify: (env: NodeJS.ProcessEnv) => string;
456	load: (...files: string[]) => NodeJS.ProcessEnv;
457	loadSafe: (...files: string[]) => NodeJS.ProcessEnv;
458	config: (def?: string, ...files: string[]) => NodeJS.ProcessEnv;
459};
460export declare const createRequire: (filename: string | URL$1) => NodeJS.Require;
461declare const globbyModule: {
462	convertPathToPattern: typeof convertPathToPattern;
463	globby: typeof globby;
464	sync: typeof globbySync;
465	globbySync: typeof globbySync;
466	globbyStream: typeof globbyStream;
467	generateGlobTasksSync: typeof generateGlobTasksSync;
468	generateGlobTasks: typeof generateGlobTasks;
469	isGitIgnoredSync: typeof isGitIgnoredSync;
470	isGitIgnored: typeof isGitIgnored;
471	isDynamicPattern: typeof isDynamicPattern;
472};
473declare const _glob: (typeof globbyModule)["globby"] & typeof globbyModule;
474declare const _YAML: YAML;
475export interface YAML {
476	parse(text: string): any;
477	stringify(object: any): string;
478	/** @deprecated */
479	parseAllDocuments(s: string, opts?: any): any[];
480	/** @deprecated */
481	parseDocument(s: string, opts?: any): any;
482	/** @deprecated */
483	isAlias(v: any): boolean;
484	/** @deprecated */
485	isCollection(v: any): boolean;
486	/** @deprecated */
487	isDocument(v: any): boolean;
488	/** @deprecated */
489	isMap(v: any): boolean;
490	/** @deprecated */
491	isNode(v: any): boolean;
492	/** @deprecated */
493	isPair(v: any): boolean;
494	/** @deprecated */
495	isScalar(v: any): boolean;
496	/** @deprecated */
497	isSeq(v: any): boolean;
498	/** @deprecated */
499	Alias: any;
500	/** @deprecated */
501	Composer: any;
502	/** @deprecated */
503	Document: any;
504	/** @deprecated */
505	Schema: any;
506	/** @deprecated */
507	YAMLSeq: any;
508	/** @deprecated */
509	YAMLMap: any;
510	/** @deprecated */
511	YAMLError: any;
512	/** @deprecated */
513	YAMLParseError: any;
514	/** @deprecated */
515	YAMLWarning: any;
516	/** @deprecated */
517	Pair: any;
518	/** @deprecated */
519	Scalar: any;
520	/** @deprecated */
521	Lexer: any;
522	/** @deprecated */
523	LineCounter: any;
524	/** @deprecated */
525	Parser: any;
526}
527export declare const depseek: typeof depseekSync;
528export declare const dotenv: typeof _default;
529declare const fs$1: typeof import("fs-extra");
530export declare const YAML: typeof _YAML;
531export declare const MAML: typeof _maml;
532export declare const glob: typeof _glob;
533export declare const nodeFetch: typeof fetch$1;
534declare const minimist$1: typeof minimist;
535declare namespace minimist$1 {
536	interface Opts extends minimist.Opts {
537	}
538	interface ParsedArgs extends minimist.ParsedArgs {
539	}
540}
541
542declare namespace _maml {
543	export { parse, stringify };
544}
545
546export {
547	fs$1 as fs,
548	minimist$1 as minimist,
549};
550
551export {};