-
Notifications
You must be signed in to change notification settings - Fork 55
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
Compass failed: You must compile individual stylesheets from the project directory. #49
Comments
I'm having the same issue as well. My config.rb is almost identical. |
I will try it. |
I've had the same problem, my gulp.src(...) path didn't have any .scss or .sass file. It might help you! |
Same here. Adding http_path to the list of options would be crucial. Really the only reason I am using config.rb. |
I've just converted over to Gulp from Grunt and I'm running into this. If anyone's had success, I'd greatly appreciate a quick note outlining your solution. |
Same here, converted from Grunt to Gulp and not able to run it correctly. Installed Compass again but no luck. |
Here is my current working solution. Keep in mind this is with a locked version of gulp-compass 1.1.7: config.rb
gulpfile.js
You'll not that the project path is different between the two. Not ideal, but this is how the plugin seems to be designed. |
@typeoneerror, would it be possible to share the directory structure for your app? I'm finding it hard to visualize the correlations between the config.rb and gulpfile.js paths... |
@typeoneerror @uberspeck +1 please! |
@kwaledesign @uberspeck no problem... Looks something like this. "source" is my "compass" folder and gulpfile and config live at the same level as that one. Here's the full gulpfile.
|
I'm having the same issue. Compass itself is working perfectly but no matter what changes I make to gulpfile.js, I just can't seem to get rid of this error. Any help would be appreciated. config.rb: http_path = "/"
css_dir = "themes/keith/static/css/"
sass_dir = "rbp/sass/" gulpfile.js gulp.task('sass', function (cb) {
gulp.src('./rbp/sass/*.scss')
.pipe(compass({
config_file: 'config.rb',
css: './themes/keith/static/css/',
scss: './rbp/sass/'
}))
.pipe(gulp.dest('./themes/keith/static/css'))
.on("end", cb);
}); |
Has anyone figured this out at all? |
@typeoneerror I tried it but perhaps I didn't do it quite right. I'll try again but the whole thing seems to be overly complicated. A simpler solution to this entire endeavour would be to just to run |
I ran into this error and solved it by making sure my directory paths from src are the same case sensitivity as my actual machine. I'm on windows so some developers use uppercase and I wasn't doing that for my src ... so I changed it to exactly how it is on the filesystem. e.g., I was pathing to "myproject/content" when I changed it to "MyProject/Content" it was all working. gulp.task('compass', function(){
var options = {
config_file : 'config.rb',
css : 'MyProject/Content',
sass : 'MyProject/Content/sass',
image : 'MyProject/Images',
javascript : 'MyProject/Scripts'
};
return gulp.src('./MyProject/Content/sass/*.sass')
.pipe(compass(options))
.pipe(gulp.dest('./MyProject/content/'));
}); |
I haven't issue with compass 0.12. My configuration works. Today, i've updated to compass 1.0.0.rc.1. Without any modification on the configuration, i have this issue too. And i can compile with compass command line. This is my task:
If i ran in debug mode, gulp ran this command : If i comment the line 70 on compass.js file, like this :
Now, it works :) |
I have fixed this a little bit differently: The problem appears not only because of line 70, as mentioned @plevavas. It is also apears because of To fix this, i commented lines // excute callback
var pathToCss = gutil.replaceExtension(path, '.css'),
contents = fs.readFileSync(pathToCss);
// Fix garbled output.
if (!(contents instanceof Buffer)) {
contents = new Buffer(contents);
}
file.path = gutil.replaceExtension(file.path, '.css');
file.contents = contents;
this.push(file); Now, it works :) btw, my config.rb file: http_path = "../"
project_path = "build"
cache_path = ".sass-cache"
css_dir = "css"
sass_dir = "sass"
images_dir = "build/images"
javascripts_dir = "build/js" |
I fixed this by using https://www.npmjs.org/package/compass. See my comment on the dupllicate issue: #61 (comment) |
|
@SleepWalker How can you archive compass built-in support with gulp-sass ? As far as I know gulp-sass works with node-sass, and node-sass use libsass, the C version of sass, while compass is written in Ruby... so I think there is no compass support. If Im wrong, can you tell my how you made this ? |
@Avcajaraville oh, excuse me. I meant |
thanks @SleepWalker |
Everybody please try 1.3.3 version. |
I am getting the following error
File : config.rb
File : gulp.js
The text was updated successfully, but these errors were encountered: