import { FilesData, IUnpackJSAPI } from '@emscripten-forge/untarjs'; import { ILock, ILogger, ISolvedPackage, TSharedLibs } from './types'; export declare function parseEnvYml(envYml: string): { prefix: string; specs: string[]; pipSpecs: string[]; channels: string[]; }; export declare function getParentDirectory(filePath: string): string; export declare function getSharedLibs(files: FilesData, prefix: string): TSharedLibs; export declare function checkWasmMagicNumber(uint8Array: Uint8Array): boolean; export declare function isCondaMeta(files: FilesData): boolean; export declare function saveFilesIntoEmscriptenFS(FS: any, files: FilesData, prefix: string): void; export declare function removeFilesFromEmscriptenFS(FS: any, paths: string[]): void; export interface IUntarCondaPackageOptions { /** * The URL to the package */ url: string; /** * The data of the package */ data?: Uint8Array; /** * The current untarjs instance */ untarjs: IUnpackJSAPI; /** * Whether the functino will be verbose or not */ verbose?: boolean; /** * Whether or not to generate conda-meta files */ generateCondaMeta?: boolean; /** * The prefix for relocation */ relocatePrefix?: string; /** * The environment Python version, if it is there */ pythonVersion?: number[]; } /** * Untar conda or empacked package, given a URL to it. This will also do prefix relocation. * @param options The functino options * @returns the files to install */ export declare function untarCondaPackage(options: IUntarCondaPackageOptions): Promise; /** * Split package info from actual package files * @param filename The original filename * @param files The package files * @param untarjs The current untarjs instance * @returns Splitted files between info and actual package files */ export declare function splitPackageInfo(filename: string, files: FilesData, untarjs: IUnpackJSAPI): Promise<{ info: FilesData; pkg: FilesData; }>; /** * Given a conda package, get the generated conda meta files * @param files The conda package files * @param verbose Whether to be verbose or not * @returns The generated conda-meta files */ export declare function getCondaMetaFile(files: FilesData, verbose: boolean): FilesData; export declare function formatChannels(channels?: string[], logger?: ILogger): Pick; export declare function computePackageChannel(pkg: ISolvedPackage, formattedChannels: Pick): string; export declare function computePackageUrl(pkg: ISolvedPackage, filename: string, channels: ILock['channelInfo']): string; export declare function join(...parts: string[]): string; export declare function cleanUrl(url: string): string; export declare function computeLockId(envDef: string): string;