import type { JsonFile, PackageJson, TextFile } from '@stacksjs/types'; /** * Reads a JSON file and returns the parsed data. */ export declare function readJsonFile(name: string, cwd?: string): Promise; /** * Reads a package.json file and returns the parsed data. */ export declare function readPackageJson(name: string, cwd?: string): Promise; /** * Writes the given text to the specified file. */ export declare function writeFile(path: string, data: any): Promise; /** * Writes the given data to the specified JSON file. */ export declare function writeJsonFile(file: JsonFile): Promise; /** * Reads a text file and returns its contents. */ export declare function readTextFile(name: string, cwd?: string): Promise; /** * Writes the given text to the specified file. */ export declare function writeTextFile(file: TextFile): Promise; export declare function doesExist(path: string): boolean; export declare function doesNotExist(path: string): boolean; /** * Determine whether a folder has any files in it. */ export declare function hasFiles(folder: string): boolean; export declare function hasComponents(): boolean; export declare function hasFunctions(): boolean; export declare function deleteFiles(dir: string, exclude?: string[]): void; export declare function getFiles(dir: string, exclude?: string[]): string[]; export declare function put(path: string, contents: string): void; export declare function get(path: string): Promise; export declare const files: Files; export declare interface Files { readJsonFile: typeof readJsonFile readPackageJson: typeof readPackageJson readTextFile: typeof readTextFile writeJsonFile: typeof writeJsonFile writeTextFile: typeof writeTextFile hasFiles: typeof hasFiles hasComponents: typeof hasComponents hasFunctions: typeof hasFunctions deleteFiles: typeof deleteFiles getFiles: typeof getFiles put: typeof put get: typeof get }