Add rubocop to our build. (#5004)

This commit is contained in:
Guo Xiang Tan
2017-07-28 10:20:09 +09:00
committed by GitHub
parent ff4e295c4f
commit 5012d46cbd
871 changed files with 5480 additions and 6056 deletions

View File

@ -15,7 +15,7 @@ module Stylesheet
footer:after { content: '#{error}' }"
end
def self.compile_asset(asset, options={})
def self.compile_asset(asset, options = {})
if Importer.special_imports[asset.to_s]
filename = "theme.scss"
@ -26,12 +26,12 @@ module Stylesheet
file = File.read path
end
compile(file,filename,options)
compile(file, filename, options)
end
def self.compile(stylesheet, filename, options={})
source_map_file = options[:source_map_file] || "#{filename.sub(".scss","")}.css.map";
def self.compile(stylesheet, filename, options = {})
source_map_file = options[:source_map_file] || "#{filename.sub(".scss", "")}.css.map";
engine = SassC::Engine.new(stylesheet,
importer: Importer,
@ -44,7 +44,6 @@ module Stylesheet
theme_field: options[:theme_field],
load_paths: [ASSET_ROOT])
result = engine.render
if options[:rtl]