Added Clone and co

This commit is contained in:
Dolan
2017-06-07 03:09:58 +01:00
parent f7b5a33770
commit 0c0761a2f4
4 changed files with 33 additions and 0 deletions

13
types/nodegit/clone-options.d.ts vendored Normal file
View File

@@ -0,0 +1,13 @@
import { CheckoutOptions } from './checkout-options';
import { FetchOptions } from './fetch-options';
export class CloneOptions {
version?: number;
checkoutOpts?: CheckoutOptions;
fetchOpts?: FetchOptions;
bare?: number;
local?: number;
checkoutBranch?: string;
repositoryCbPayload?: void;
remoteCbPayload?: void;
}

16
types/nodegit/clone.d.ts vendored Normal file
View File

@@ -0,0 +1,16 @@
import { Repository } from './repository';
import { CloneOptions } from './clone-options';
export namespace Clone {
enum LOCAL {
AUTO = 0,
LOCAL = 1,
NO_LOCAL = 2,
NO_LINKS = 3
}
}
export class Clone {
static clone(url: string, local_path: string, options?: CloneOptions): Promise<Repository>;
static initOptions(opts: CloneOptions, version: number): number;
}

View File

@@ -13,6 +13,8 @@ export { Branch } from './branch';
export { Buf } from './buf';
export { CheckoutOptions } from './checkout-options';
export { Checkout } from './checkout';
export { CloneOptions } from './clone-options';
export { Clone } from './clone';
export { Commit } from './commit';
export { Config } from './config';
export { ConvenientPatch } from './convenient-patch';

View File

@@ -26,6 +26,8 @@
"buf.d.ts",
"checkout-options.d.ts",
"checkout.d.ts",
"clone-options.d.ts",
"clone.d.ts",
"commit.d.ts",
"config.d.ts",
"convenient-patch.d.ts",