Download github repo with ease.
$ npm install --save download-repo
const downloadRepo = require('download-repo')
// download egoist/tooling's master branch archive
downloadRepo('egoist/tooling', {target: 'tooling'})
.then(() => {
console.log('done, `cd tooling` to check out more!')
})
// download reactjs/redux by tag v4.0.0
downloadRepo('reactjs/redux', {target: 'redux', tag: 'v4.0.0'})
.then(() => {
console.log('done, `cd redux` to check out more!')
})
Type: string
User's repo, format like owner/repo
Type: string
Default: the original filename, format like reponame-[branch|tag]
The target name.
Type: string
Default: process.cwd()
The directory to move the target to.
Type: string
Default: master
The branch to download.
Type: string
The tag to download, will override branch
if set.
Type: boolean
Default: false
Omit the progress bar when downloading.
MIT © EGOIST