From ce3f1a08722afc4e0f4a393cd5b180880c5dca5e Mon Sep 17 00:00:00 2001 From: Koki Takahashi Date: Tue, 11 Oct 2016 16:13:17 +0900 Subject: [PATCH] fix: Skip sourcemapping in Node.js 0.12 --- Gulpfile.ls | 19 +++++++++++++------ package.json | 2 +- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/Gulpfile.ls b/Gulpfile.ls index 94e86b2..c8f6d31 100644 --- a/Gulpfile.ls +++ b/Gulpfile.ls @@ -4,16 +4,23 @@ require! { \vinyl-source-stream \gulp-livescript \gulp-rename - \gulp-sourcemaps \lcov-sourcemap } +if process.env.TRAVIS_NODE_VERSION isnt '0.12' + gulp-sourcemaps = require \gulp-sourcemaps + gulp.task \livescript -> - gulp.src <[*.ls test/*.ls !browser.ls !Gulpfile.ls]> base: \. - .pipe gulp-sourcemaps.init! - .pipe gulp-livescript! - .pipe gulp-sourcemaps.write \. - .pipe gulp.dest \. + if process.env.TRAVIS_NODE_VERSION isnt '0.12' + gulp.src <[*.ls test/*.ls !browser.ls !Gulpfile.ls]> base: \. + .pipe gulp-sourcemaps.init! + .pipe gulp-livescript! + .pipe gulp-sourcemaps.write \. + .pipe gulp.dest \. + else + gulp.src <[*.ls test/*.ls !browser.ls !Gulpfile.ls]> base: \. + .pipe gulp-livescript! + .pipe gulp.dest \. gulp.task \browserify -> browserify \browser.ls do diff --git a/package.json b/package.json index a65e5e0..0fb659f 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "scripts": { "test": "gulp build && intern-client config=test/intern-node", "build": "gulp build", - "coveralls": "gulp transform-lcov && cat lcov.info | coveralls", + "coveralls": "test \"$TRAVIS_NODE_VERSION\" = 0.12 || gulp transform-lcov && cat lcov.info | coveralls", "semantic-release": "semantic-release pre && npm publish && semantic-release post" }, "repository": {