Skip to content

Commit

Permalink
Added contributing guide and updated watch task
Browse files Browse the repository at this point in the history
  • Loading branch information
gfranko committed Jun 19, 2014
1 parent 47609bc commit e45c887
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 3 deletions.
16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,22 @@ gifshot.takeSnapShot(function(obj) {
'numWorkers': 2
```

## Contributing

Please send all PR's to the `dev` branch.

If your PR is a code change:

1. Install all node.js dev dependencies: `npm install`
2. Update the appropriate module inside of the `src/modules` directory.
3. Install gulp.js globally: `sudo npm install gulp -g`
4. Lint and Minify with Gulp: `gulp`
5. Verify that the minified output file has been updated in `build/gifshot.js` and `build/gifshot.min.js`
6. Send the PR!

**Note:** There is a gulp `watch` task set up that will automatically build, lint, and minify gifshot whenever a module inside of the `src/modules` directory is changed. We recommend using it.


## Credits

gifshot.js would not have been possible without the help/inspiration of the following libraries/awesome people:
Expand Down
5 changes: 2 additions & 3 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,7 @@ gulp.task('default', ['clean','lint', 'minify', 'add-unminified-file-to-build'])

// The watch task
gulp.task('watch', function() {
var watcher = gulp.watch('src/modules/**', ['default']);
watcher.on('change', function(event) {
console.log('File '+event.path+' was '+event.type+', running tasks...');
gulp.watch('src/modules/*.js', function(event) {
gulp.start('default');
});
});

0 comments on commit e45c887

Please sign in to comment.