Fork me on GitHub
nodegit by tbranyen & faceleg

Methods

repo(directory, callback) → {Repo|null}

Create a new Repo object. If directory is not provided, simply return it. Otherwise open the repo asynchronously.
Parameters:
Name Type Description
directory String | null The directory for the git repo to open. Null if one does not want to open a repo.
callback repoCallback | null
Source:
Returns:
The Repo if no directory is provided, else undefined.
Type
Repo | null

Type Definitions

repoCallback(error, repo)

Parameters:
Name Type Description
error GitError | null An Error or null if successful.
repo Repo | null Opened repository.
Source: