Class: WPRoot::Compass

Inherits:
Object
  • Object
show all
Defined in:
lib/wproot/compass.rb

Instance Method Summary collapse

Constructor Details

#initialize(content) ⇒ Compass

Returns a new instance of Compass.



3
4
5
# File 'lib/wproot/compass.rb', line 3

def initialize(content)
  @content = content
end

Instance Method Details

#compileObject



7
8
9
10
11
12
13
# File 'lib/wproot/compass.rb', line 7

def compile
  IO.popen('sass --compass -s', 'w+') do |io|
    io.write(@content)
    io.close_write
    io.read
  end
end