UNPKG

go-git-it

Version:

Download any repository or subdirectory on GitHub with support for Node.js and the CLI

21 lines (20 loc) 608 B
export interface GitHubUrlData { owner: string; project: string; branch: string; filePath: string; isMainRepo: boolean; isReleaseAsset: boolean; isFile: boolean; downloadUrl?: string; } export declare function parseGitHubUrl(gitUrl: string): GitHubUrlData; export declare function isValidGitHubUrl(url: string): boolean; export declare function generateApiUrls(data: GitHubUrlData): { repository: string; branches: string; contents: string; releases: string; archive: string; }; export declare function getOutputDirectoryName(data: GitHubUrlData): string;