112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
|
# File 'lib/isodoc/gem_tasks.rb', line 112
def compile_scss(filename)
require "sassc"
isodoc_path = if Gem.loaded_specs["isodoc"]
File.join(Gem.loaded_specs["isodoc"].full_gem_path,
"lib", "isodoc")
else
File.join("lib", "isodoc")
end
[isodoc_path,
File.dirname(filename)].each do |name|
SassC.load_paths << name
end
sheet_content = File.read(filename, encoding: "UTF-8")
SassC::Engine.new(fonts_placeholder + sheet_content,
syntax: :scss,
importer: SasscImporter)
.render
end
|