Skip to content

Instantly share code, notes, and snippets.

@digitalkaoz
Created March 27, 2015 11:39
Show Gist options
  • Save digitalkaoz/ec98547f794291d7a0e1 to your computer and use it in GitHub Desktop.
Save digitalkaoz/ec98547f794291d7a0e1 to your computer and use it in GitHub Desktop.
phpspec watcher with gulp
var gulp = require('gulp');
var shell = require('gulp-shell');
var plumber = require('gulp-plumber');
gulp.task('run', function() {
gulp.src('')
.pipe(plumber())
.pipe(shell('vendor/bin/phpspec run -fdot -v --stop-on-failure --ansi'))
;
});
gulp.task('default', ['run'], function() {
gulp.watch(['src/**/*.php', 'spec/**/*.php'], ['run']);
});
{
"dependencies": {
"gulp": "^3.8.11",
"gulp-plumber": "^1.0.0",
"gulp-shell": "^0.4.0"
}
}
@digitalkaoz
Copy link
Author

$ npm install

simply run node_modules/.bin/gulpand happy speccing :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment