Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when using merge-stream #31

Open
Jenselme opened this issue May 21, 2015 · 3 comments
Open

Error when using merge-stream #31

Jenselme opened this issue May 21, 2015 · 3 comments
Labels

Comments

@Jenselme
Copy link

I am trying to concatenate the output of gulp-run with files coming from gulp.src. To do this, I use merge-stream and gulp-concat. I get the following error:

events.js:72
        throw er; // Unhandled 'error' event
              ^
Error: Streaming not supported

If I remove .exec(), I don't have the error but no file is created (I find this logically according to the documentation). If I use gulp-shell instead everything is fine.

Here is my task:

var merge = require('merge-stream');
var concat = require('gulp-concat');

gulp.task('build.js', ['js-files'], function () {
    var jsFiles = fs.readFileSync('/tmp/geo-front3/js-files')
        .toString()
        .replace('\n', ' ');

    var appJs = run('closure-compiler ' +
    jsFiles  +
    '--compilation_level SIMPLE_OPTIMIZATIONS ' +
    '--jscomp_error checkVars ' +
    '--externs externs/ol.js ' +
    '--externs externs/angular.js ' +
    '--externs externs/jquery.js ').exec();

    var libSrc = gulp.src([
        'src/lib/jquery-2.0.3.min.js',
        'src/lib/bootstrap-3.3.1.min.js',
        'src/lib/moment-with-customlocales.min.js',
        'src/lib/typeahead-0.9.3.min.js src/lib/angular.min.js',
        'src/lib/proj4js-compressed.js',
        'src/lib/EPSG*.js',
        'src/lib/ol.js',
        'src/lib/angular-translate.min.js',
        'src/lib/angular-translate-loader-static-files.min.js',
        'src/lib/fastclick.min.js',
        'src/lib/localforage.min.js',
        'src/lib/filesaver.min.js',
    ]);

    merge(libSrc, appJs)
        .pipe(concat('build.js'))
        .pipe(gulp.dest('prd/lib'));
});
@m19c m19c added the bug label Feb 4, 2016
@bezenson
Copy link

bezenson commented Mar 7, 2016

Have you resolved it somehow? I have the same problem

@Jenselme
Copy link
Author

Jenselme commented Mar 7, 2016

@inferusvv I haven't. I changed how our build process works to avoid the problem.

@craigmdennis
Copy link

Also getting this issue with no clear reason in the NPM logs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants