{"action":"created","issue":{"url":"https://api.github.com/repos/gruntjs/grunt-contrib-cssmin/issues/155","labels_url":"https://api.github.com/repos/gruntjs/grunt-contrib-cssmin/issues/155/labels{/name}","comments_url":"https://api.github.com/repos/gruntjs/grunt-contrib-cssmin/issues/155/comments","events_url":"https://api.github.com/repos/gruntjs/grunt-contrib-cssmin/issues/155/events","html_url":"https://github.com/gruntjs/grunt-contrib-cssmin/issues/155","id":53191880,"number":155,"title":"CleanCSS \"sourceMap\" option isn't working","user":{"login":"xiehan","id":855115,"avatar_url":"https://avatars.githubusercontent.com/u/855115?v=3","gravatar_id":"","url":"https://api.github.com/users/xiehan","html_url":"https://github.com/xiehan","followers_url":"https://api.github.com/users/xiehan/followers","following_url":"https://api.github.com/users/xiehan/following{/other_user}","gists_url":"https://api.github.com/users/xiehan/gists{/gist_id}","starred_url":"https://api.github.com/users/xiehan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xiehan/subscriptions","organizations_url":"https://api.github.com/users/xiehan/orgs","repos_url":"https://api.github.com/users/xiehan/repos","events_url":"https://api.github.com/users/xiehan/events{/privacy}","received_events_url":"https://api.github.com/users/xiehan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2014-12-31T16:41:56Z","updated_at":"2015-01-22T18:05:18Z","closed_at":null,"body":"I was pretty excited when the new version upgraded clean-css to v3.0.1 so we can finally generate CSS sourcemaps, but I can't seem to get it to work.\r\n\r\nI'm doing:\r\n\r\n    cssmin: {\r\n      options: {\r\n        sourceMap: true,\r\n        target: 'release/css'\r\n      },\r\n      target: {\r\n        files: [{\r\n          expand: true,\r\n          cwd: 'release/css',\r\n          src: ['*.css', '!*.min.css'],\r\n          dest: 'release/css',\r\n          ext: '.min.css'\r\n        }]\r\n      }\r\n    }\r\n\r\nThe minified CSS files are created just fine, but no sourcemaps are generated.\r\n\r\nI have no experience writing or debugging Grunt plugins so I have no idea where the problem lies. However, I installed CleanCSS globally so I could use its CLI, and I managed to generate source maps perfectly from the command line, so the problem doesn't appear to be with CleanCSS as far as I can tell."},"comment":{"url":"https://api.github.com/repos/gruntjs/grunt-contrib-cssmin/issues/comments/71067408","html_url":"https://github.com/gruntjs/grunt-contrib-cssmin/issues/155#issuecomment-71067408","issue_url":"https://api.github.com/repos/gruntjs/grunt-contrib-cssmin/issues/155","id":71067408,"user":{"login":"danny-englander","id":609623,"avatar_url":"https://avatars.githubusercontent.com/u/609623?v=3","gravatar_id":"","url":"https://api.github.com/users/danny-englander","html_url":"https://github.com/danny-englander","followers_url":"https://api.github.com/users/danny-englander/followers","following_url":"https://api.github.com/users/danny-englander/following{/other_user}","gists_url":"https://api.github.com/users/danny-englander/gists{/gist_id}","starred_url":"https://api.github.com/users/danny-englander/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danny-englander/subscriptions","organizations_url":"https://api.github.com/users/danny-englander/orgs","repos_url":"https://api.github.com/users/danny-englander/repos","events_url":"https://api.github.com/users/danny-englander/events{/privacy}","received_events_url":"https://api.github.com/users/danny-englander/received_events","type":"User","site_admin":false},"created_at":"2015-01-22T18:05:18Z","updated_at":"2015-01-22T18:05:18Z","body":"According to this issue, https://github.com/gruntjs/grunt-contrib-cssmin/issues/58, this is supposed to be fixed now but I could not get it to work either. Min files are generated but with no sourcemaps using code similar to that of the OP. "}}