@launchmenu/launcher
Version:
The installer + launcher of LM
38 lines • 1.8 kB
TypeScript
/**
* Install the core LM module
* @param root The root directory to install the packages in
* @param packageName The package to install
* @param packages Additional packages to install
*/
export declare function install(root: string, packageName: string, ...packages: string[]): Promise<void>;
/**
* Checks whether a package with the specified name is installed
* @param externalRoot The path to check for external packages
* @param packageName The package to check for
* @param externalOnly Whether to only check for external packages
* @returns Whether the specified package is installed
*/
export declare function isInstalled(externalRoot: string, packageName: string, externalOnly?: boolean): boolean;
/**
* Retrieves the name of the package without version number
* @param packageName The name of the package possibly including version number
* @returns The name of the package
*/
export declare function getPackageNameWithoutVersion(packageName: string): string;
/**
* Retrieves the absolute path to a package with the given name
* @param root The root directory to look for packages in
* @param packageName The package to get the path of
* @returns The path to the package
* @throw Throws an error if no such path exists
*/
export declare function getInstalledPath(root: string, packageName: string): string;
/**
* Retrieves the absolute path to a package with the given name, if externally installed
* @param root The root directory to look for packages in
* @param packageName The package to get the path of
* @returns The path to the package
* @throw Throws an error if no such path exists
*/
export declare function getExternalInstallPath(root: string, packageName: string): string;
//# sourceMappingURL=installer.d.ts.map