easy-nodegit
A simple and elegant git client base on nodegit.
install
npm install easy-nodegit --save
Usage
Simple git client API, just like using git command:
const GitClient = const client = '/path/to/repo/work/directory' type: 'ssh' // support 'ssh' or 'http', default is 'ssh' // when type == 'ssh' privateKey: '/path/to/privateKey' // default is ~/.ssh/id_rsa publicKey: '/path/to/publicKey' // default is ~/.ssh/id_rsa.pub // when type == 'http' username: '...' password: '...' { // clone await client // add await client await client // reset await client // remove await client // commit await client // pull await client // push await client}
API
see API.md
LICENSE
MIT