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

"File to read not found or unreadable" with concat + sourcemaps #151

Closed
ghost opened this issue Dec 22, 2014 · 1 comment
Closed

"File to read not found or unreadable" with concat + sourcemaps #151

ghost opened this issue Dec 22, 2014 · 1 comment

Comments

@ghost
Copy link

ghost commented Dec 22, 2014

I'm trying to use this plugin with gulp-concat and gulp-sourcemaps. Using one or the other in my gulp task works perfectly, but using both together causes "Error: File to read not found or unreadable: /path/to/filename/given/to/concat.css"

I've thrown together a quick minimal scenario to illustrate the problem: https://github.com/parsnick/gulp-sass-error-with-concat

gulpfile.js:

var gulp       = require('gulp');
var concat     = require('gulp-concat');
var sourcemaps = require('gulp-sourcemaps');
var sass       = require('gulp-sass');

gulp.task('sass', function () {

  gulp.src('src/**/*.scss')
      .pipe(concat('all.css'))
      .pipe(sass())
      .pipe(gulp.dest('dist/'));
});

gulp.task('sassMap', function () {

  gulp.src('src/**/*.scss')
      .pipe(sourcemaps.init())
      .pipe(concat('allWithMap.css'))
      .pipe(sass())
      .pipe(sourcemaps.write())
      .pipe(gulp.dest('dist/'));
});

gulp.task('default', ['sass', 'sassMap']);

sass task runs fine, sassMap throws the error.

sassMap can work by simply piping to gulp-concat after gulp-sass, but that's not quite so easy in my actual gulpfile as there's a bit more going on!

@jmm
Copy link

jmm commented Jan 2, 2015

This is due to a bug in gulp-sass. See #158.

@ghost ghost closed this as completed Feb 3, 2015
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant