UNPKG

@nodesecure/github

Version:
44 lines 1.07 kB
export interface DownloadOptions { /** * The destination (location) to extract the tar.gz * * @default process.cwd() */ dest?: string; /** * The default github branch name (master, main ...) * * @default main */ branch?: string; /** * Authentication token for private repositories * * @default process.env.GITHUB_TOKEN */ token?: string; } export interface DownloadResult { /** Archive or repository location on disk */ location: string; /** Github repository name */ repository: string; /** Github organization name */ organization: string; /** Github branch name */ branch: string; } /** * @example * const { location } = await github.download("NodeSecure.utils", { * dest: __dirname * }); * console.log(location); */ export declare function download(repository: string, options?: DownloadOptions): Promise<{ location: string; organization: string; repository: string; branch: string; }>; //# sourceMappingURL=download.d.ts.map