{"action":"created","issue":{"url":"https://api.github.com/repos/owen2345/camaleon-cms/issues/56","labels_url":"https://api.github.com/repos/owen2345/camaleon-cms/issues/56/labels{/name}","comments_url":"https://api.github.com/repos/owen2345/camaleon-cms/issues/56/comments","events_url":"https://api.github.com/repos/owen2345/camaleon-cms/issues/56/events","html_url":"https://github.com/owen2345/camaleon-cms/issues/56","id":105570485,"number":56,"title":"Sass style support","user":{"login":"delphaber","id":139284,"avatar_url":"https://avatars.githubusercontent.com/u/139284?v=3","gravatar_id":"","url":"https://api.github.com/users/delphaber","html_url":"https://github.com/delphaber","followers_url":"https://api.github.com/users/delphaber/followers","following_url":"https://api.github.com/users/delphaber/following{/other_user}","gists_url":"https://api.github.com/users/delphaber/gists{/gist_id}","starred_url":"https://api.github.com/users/delphaber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/delphaber/subscriptions","organizations_url":"https://api.github.com/users/delphaber/orgs","repos_url":"https://api.github.com/users/delphaber/repos","events_url":"https://api.github.com/users/delphaber/events{/privacy}","received_events_url":"https://api.github.com/users/delphaber/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-09T10:39:53Z","updated_at":"2015-09-14T16:26:27Z","closed_at":null,"body":"Hi :)\r\n\r\nI've found a problem in production with `rake assets:precompile` using the `sass` syntax. This can be reproduced locally with https://github.com/delphaber/camaleon-test-sass and `rake assets:precompile`\r\n\r\n```bash\r\n$ rake assets:precompile\r\nrake aborted!\r\nSass::SyntaxError: Undefined variable: \"$red\".\r\n/Users/faber/Repos/blog/app/apps/themes/puppa/assets/css/_base.css.sass:2\r\n-e:1:in `<main>'\r\nTasks: TOP => assets:precompile\r\n(See full trace by running task with --trace)\r\n```\r\n\r\nSprockets tries to compile `_base.css.sass` but can't find the variable defined in `_colors.css.sass`.\r\n\r\nI think this happens because `/config/initializers/assets.rb` tells sprockets to compile any `.css` (so, `.sass` too) separately. Sprocket should compile only `main.css.sass` which imports the other two files.\r\n\r\nI tried to remove any `.css` related rule in `/config/initializers/assets.rb` and I was able to `rake assets:precompile` successfully.\r\n\r\nAny clue? :)"},"comment":{"url":"https://api.github.com/repos/owen2345/camaleon-cms/issues/comments/140133878","html_url":"https://github.com/owen2345/camaleon-cms/issues/56#issuecomment-140133878","issue_url":"https://api.github.com/repos/owen2345/camaleon-cms/issues/56","id":140133878,"user":{"login":"cmckni3","id":735717,"avatar_url":"https://avatars.githubusercontent.com/u/735717?v=3","gravatar_id":"","url":"https://api.github.com/users/cmckni3","html_url":"https://github.com/cmckni3","followers_url":"https://api.github.com/users/cmckni3/followers","following_url":"https://api.github.com/users/cmckni3/following{/other_user}","gists_url":"https://api.github.com/users/cmckni3/gists{/gist_id}","starred_url":"https://api.github.com/users/cmckni3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cmckni3/subscriptions","organizations_url":"https://api.github.com/users/cmckni3/orgs","repos_url":"https://api.github.com/users/cmckni3/repos","events_url":"https://api.github.com/users/cmckni3/events{/privacy}","received_events_url":"https://api.github.com/users/cmckni3/received_events","type":"User","site_admin":false},"created_at":"2015-09-14T16:26:27Z","updated_at":"2015-09-14T16:26:27Z","body":"This happens in vanilla Rails apps as well.\r\n\r\nYou need to add an `@import 'colors'` to your `_base.css.sass` file. Alternatively, you should look at a different way of [structuring your sass files](http://stackoverflow.com/questions/9138946/proper-scss-asset-structure-in-rails) (I would recommend switching to scss as well)."}}