Now there is a Gulp configuration in which all the scripts are written into one .css file. But you need to separate the files with the suffix -ie (fname-ie.styl) and collect them separately, next to the (common) .min.css file.

gulp.task('styles', () => ( gulp.src('app/styles/*.styl') .pipe(stylus({ use: [ importIfExist(), rupture() ], 'include css': true })) .pipe(rename({suffix: '.min'})) .pipe(gulp.dest('dist/assets/styles')) )); 
  • It is probably possible to separate the streams and process them in different ways. But I think you need a very powerful witch. Much more than the losses from the launch of another task. - user207618

2 answers 2

I use this build option:

 gulp.task('styles', () => ( gulp.src(['app/styles/*.styl', '!app/styles/*-ie.styl']) .pipe(stylus({ use: [ importIfExist(), rupture() ], 'include css': true })) .pipe(rename({suffix: '.min'})) .pipe(gulp.dest('dist/assets/styles')) )); gulp.task('styles-ie', () => ( gulp.src('app/styles/*-ie.styl') .pipe(stylus({ use: [ importIfExist(), rupture() ], 'include css': true })) .pipe(rename({suffix: '.min'})) .pipe(gulp.dest('dist/assets/styles')) )); 
  • No, because it all lays down in one file ... here you need a rule, so that with -ie would not lie and the second rule, so that with -ie in css would collect separately ... - CodeGust
  • one
    for this use a separate task. - DimenSi

For such situations it is worth making a separate task.