Error creating source map - configure grunt and sass

I am trying to use sass with grunt. I installed ruby, sass and grunts in my way.
Versions:

node: 0.10.20
  npm: 1.3.11
  grunt-cli: 0.1.13
  grunt: 0.4.5
  sass: 3.4.4

my json package is,

"private": true,
"devDependencies": {
    "express": "4.x",
    "grunt": "~0.4.1",
    "grunt-contrib-sass": "~0.3.0",
    "grunt-contrib-watch": "~0.4.4" 
}

my grunt file,

module.exports = function(grunt) {
    grunt.initConfig({
        pkg: grunt.file.readJSON('package.json'),
        sass: {
            dist: {
                files: {
                    'style/style.css' : 'sass/home.scss'
                }
            }
        },
        watch: {
            css: {
                files: '**/*.scss',
                tasks: ['sass']
            }
        }
    });
    grunt.loadNpmTasks('grunt-contrib-sass');
    grunt.loadNpmTasks('grunt-contrib-watch');
    grunt.registerTask('default',['watch']);
}

Now, if I tried the grunt command, I get the following error. Any help?

run: grumble or rub watch or grumble sassi

Error:

Running "sass:dist" (sass) task
Error: Error generating source map: couldn't determine public URL for the source
 stylesheet.
         No filename is available so there nothing for the source map to link
to.
        on line  of standard input
  Use --trace for backtrace.
Warning: Error: Error generating source map: couldn't determine public URL for t
he source stylesheet.
         No filename is available so there nothing for the source map to link
to.
        on line  of standard input
  Use --trace for backtrace. Use --force to continue.

Aborted due to warnings.

any idea?

+4
source share
2 answers

, . gem install compass. grunt, , - .

, , , . , .

sourcemap: none sass.

Update:

. tree -I node_modules ( - ), ?

, .

.
├── Gruntfile.js
├── package.json
├── sass
│   └── style.scss
└── style
    ├── style.css
    └── style.css.map

: , . :

npm-check-updates

npm install npm-check-updates 

  • npm-check-updates , .
  • npm-check-updates -u package.json
  • npm update, .
+3

node ..

npm-check-updates , npm-check-updates -u . json npm .

-2

All Articles