mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
Initial commit of files
This commit is contained in:
parent
e3a587edc9
commit
7ded9e7db4
6
types/nodegit/index.d.ts
vendored
Normal file
6
types/nodegit/index.d.ts
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
// Type definitions for nodegit 0.18
|
||||
// Project: https://github.com/nodegit/nodegit
|
||||
// Definitions by: Dolan Miu <https://github.com/dolanmiu>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
export { Repository } from './repository';
|
||||
5
types/nodegit/nodegit-tests.ts
Normal file
5
types/nodegit/nodegit-tests.ts
Normal file
@ -0,0 +1,5 @@
|
||||
import * as Git from 'nodegit';
|
||||
|
||||
Git.Repository.discover("startPath", 1, "ceilingDirs").then((string) => {
|
||||
// Use string
|
||||
});
|
||||
71
types/nodegit/repository.d.ts
vendored
Normal file
71
types/nodegit/repository.d.ts
vendored
Normal file
@ -0,0 +1,71 @@
|
||||
interface RepositoryInitOptions {
|
||||
description: string,
|
||||
flags: number,
|
||||
initialHead: string,
|
||||
mode: number,
|
||||
originUrl: string,
|
||||
templatePath: string,
|
||||
version: number,
|
||||
workdirPath: string
|
||||
}
|
||||
|
||||
|
||||
export class Repository {
|
||||
/**
|
||||
* Creates a branch with the passed in name pointing to the commit
|
||||
*
|
||||
* @static
|
||||
* @param {string} startPath
|
||||
* @param {number} acrossFs
|
||||
* @param {string} ceilingDirs
|
||||
* @returns {Promise<string>}
|
||||
*
|
||||
* @memberof Repository
|
||||
*/
|
||||
static discover(startPath: string, acrossFs: number, ceilingDirs: string): Promise<string>;
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @static
|
||||
* @param {string} path
|
||||
* @param {boolean} [isBare]
|
||||
* @returns {Promise<Repository>}
|
||||
*
|
||||
* @memberof Repository
|
||||
*/
|
||||
static init(path: string, isBare?: boolean): Promise<Repository>;
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @static
|
||||
* @param {string} repoPath
|
||||
* @param {RepositoryInitOptions} [options]
|
||||
* @returns {Promise<Repository>}
|
||||
*
|
||||
* @memberof Repository
|
||||
*/
|
||||
static initExt(repoPath: string, options?: RepositoryInitOptions): Promise<Repository>;
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @static
|
||||
* @param {string} path
|
||||
* @returns {Promise<Repository>}
|
||||
*
|
||||
* @memberof Repository
|
||||
*/
|
||||
static open(path: string): Promise<Repository>;
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @static
|
||||
* @param {string} barePath
|
||||
* @returns {Promise<Repository>}
|
||||
*
|
||||
* @memberof Repository
|
||||
*/
|
||||
static openBare(barePath: string): Promise<Repository>;
|
||||
static openExt(path: string, flags?: number, ceilingDirs?: string): Promise<Repository>;
|
||||
|
||||
// getBranchCommit(name: string): Promise<Commit>;
|
||||
}
|
||||
23
types/nodegit/tsconfig.json
Normal file
23
types/nodegit/tsconfig.json
Normal file
@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": false,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"nodegit-tests.ts",
|
||||
"repository.d.ts"
|
||||
]
|
||||
}
|
||||
6
types/nodegit/tslint.json
Normal file
6
types/nodegit/tslint.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"extends": "dtslint/dt.json",
|
||||
"rules": {
|
||||
"ban-types": false
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user