0
我有一個git子模塊中的整個bootstrap-sass項目。爲什麼咕嚕地看着sass/bootstrap/test /根本沒有 - 當我只告訴它看看sass/bootstrap/vendor?爲什麼Grunt忽略我的文件路徑?
'use strict';
module.exports = function(grunt) {
grunt.initConfig({
compass: {
dist: {
options: {
sassDir: 'sass',
cssDir: 'style'
},
files: {
'style/bootstrap.css': 'sass/bootstrap/vendor/assets/stylesheets/bootstrap.scss'
}
}
},
watch: {
sass: {
files: [
'sass/bootstrap/vendor/assets/stylesheets'
],
tasks: ['compass']
}
}
});
grunt.loadNpmTasks('grunt-contrib-compass');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.registerTask('default', [
'compass',
'watch'
]);
};
$ grunt
:因爲你沒有指定單獨的文件
Running "compass:dist" (compass) task
directory style/bootstrap/templates/project/
directory style/bootstrap/test/dummy_sass_only/
directory style/bootstrap/test/dummy_node_mincer/
directory style/bootstrap/vendor/assets/stylesheets/
directory style/bootstrap/vendor/assets/stylesheets/bootstrap/
directory style/bootstrap/test/dummy_rails/app/assets/stylesheets/
error sass/bootstrap/templates/project/styles.sass (Line 1: File to import not found or unreadable: bootstrap-compass.
不知道如何解決它? –
如果你想單獨使用'grunt-contrib-sass'編譯sass文件。指南針,它的框架沒有解決方法。 –