Skip to content

Commit

Permalink
Merge pull request #367 from eleven-labs/fix-gulp-style-errorHandler
Browse files Browse the repository at this point in the history
Add event handler on "error" for gulp styles task
  • Loading branch information
Swiip committed Feb 23, 2015
2 parents 60d7c24 + d21470a commit 2bf40ee
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
5 changes: 5 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ node_js:
- '0.12'
- iojs

matrix:
fast_finish: true
allow_failures:
- node_js: iojs

before_install:
- npm install -g npm@latest
- npm install -g bower
Expand Down
8 changes: 4 additions & 4 deletions app/templates/gulp/_styles.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ module.exports = function(options) {
.pipe($.inject(injectFiles, injectOptions))
.pipe(indexFilter.restore())
<% if (props.cssPreprocessor.key === 'less') { %>
.pipe($.less(lessOptions))
.pipe($.less(lessOptions)).on('error', options.errorHandler('Less'))
<% } else if (props.cssPreprocessor.key === 'ruby-sass') { %>
.pipe($.rubySass(sassOptions))
.pipe($.rubySass(sassOptions)).on('error', options.errorHandler('RubySass'))
<% } else if (props.cssPreprocessor.key === 'node-sass') { %>
.pipe($.sass(sassOptions))
.pipe($.sass(sassOptions)).on('error', options.errorHandler('Sass'))
<% } else if (props.cssPreprocessor.key === 'stylus') { %>
.pipe($.stylus())
.pipe($.stylus()).on('error', options.errorHandler('Stylus'))
<% } %>

.pipe($.autoprefixer())
Expand Down

0 comments on commit 2bf40ee

Please sign in to comment.