https://github.com/junosuarez/node-vinyl-github-src
node module: use github repos as a vinyl (gulp) source
https://github.com/junosuarez/node-vinyl-github-src
Last synced: 10 months ago
JSON representation
node module: use github repos as a vinyl (gulp) source
- Host: GitHub
- URL: https://github.com/junosuarez/node-vinyl-github-src
- Owner: junosuarez
- License: isc
- Created: 2014-05-31T06:15:54.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2014-05-31T06:43:55.000Z (about 12 years ago)
- Last Synced: 2025-09-08T16:43:38.305Z (11 months ago)
- Language: JavaScript
- Size: 125 KB
- Stars: 6
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# vinyl-github-src
use github repos as a vinyl (gulp) source
## usage
```js
var githubSrc = require('vinyl-github-src')
var vinylFs = require('vinyl-fs')
githubSrc('jden/node-vinyl-github-src')
.pipe(vinylFs.dest('./repo'))
```
Downloads a this module's repository to the `./repo` directory
Usage with [`gulp`](https://npm.im/gulp) is similar:
```js
var gulp = require('gulp')
var githubSrc = require('vinyl-github-src')
githubSrc('jden/node-vinyl-github-src')
.pipe(gulp.dest('./repo'))
```
## api
### `vinylGithubSrc(repo: String, opts?: Object) => VinylSourceStream`
`repo` should be a string like `username/repo`
`opts` is an options object with any of the following keys:
- `opts.ref` - the git reference to use (branch, tag, or commit hash). defaults to `"master"`
## installation
$ npm install vinyl-github-src
## running the tests
From package root:
$ npm install
$ npm test
## contributors
- jden
## license
ISC. (c) MMXIV jden . See LICENSE.md