lib/front_compiler.rb
# compacts css-source from the given file
compacts css-source from the given file
compacts css - source from the given file
def compact_css(file_name)
      source = File.open(file_name).read
      source.gsub! /\/\*.*?\*\//m, ''
      source.gsub! /\n\s*\n/im, "\n"
      source.gsub! /\n\s*/im, "\n"
      source.gsub! /\s*(\{|\)|\(|;|,|:)\s*/im, '\1'
      source
    end
def compact_css ( file_name ) source = File . open ( file_name ) . read source . gsub! / \/ \* .*? \* \/ /m , '' source . gsub! / \n \s * \n /im , "\n" source . gsub! / \n \s * /im , "\n" source . gsub! / \s *( \{ | \) | \( |;|,|:) \s * /im , '\1' source end
compacts css-source from the given file
compacts css - source from the given file
file_name
<not_specific>