From f775fa0ca030629e3aa116b496fdf5d131121d28 Mon Sep 17 00:00:00 2001 From: Chris Eppstein Date: Sun, 24 Apr 2011 19:56:29 -0700 Subject: [PATCH 1/3] Correct the CLI help on the default value of environment. --- lib/compass/exec/project_options_parser.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/compass/exec/project_options_parser.rb b/lib/compass/exec/project_options_parser.rb index e7fbfc54..fa3052ff 100644 --- a/lib/compass/exec/project_options_parser.rb +++ b/lib/compass/exec/project_options_parser.rb @@ -37,14 +37,14 @@ module Compass::Exec::ProjectOptionsParser end opts.on('-e ENV', '--environment ENV', [:development, :production], 'Use sensible defaults for your current environment.', - ' One of: development, production (default)') do |env| + ' One of: development (default), production') do |env| self.options[:environment] = env - end + end opts.on('-s STYLE', '--output-style STYLE', [:nested, :expanded, :compact, :compressed], 'Select a CSS output mode.', ' One of: nested, expanded, compact, compressed') do |style| self.options[:output_style] = style - end + end opts.on('--relative-assets', :NONE, 'Make compass asset helpers generate relative urls to assets.') do self.options[:relative_assets] = true From 4957774e49539a6d81a42a9a6690af22dd4c57cf Mon Sep 17 00:00:00 2001 From: Chris Eppstein Date: Sun, 24 Apr 2011 19:57:45 -0700 Subject: [PATCH 2/3] Default production mode to compressed output --- lib/compass/configuration/defaults.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/compass/configuration/defaults.rb b/lib/compass/configuration/defaults.rb index ec6ce392..7c9add32 100644 --- a/lib/compass/configuration/defaults.rb +++ b/lib/compass/configuration/defaults.rb @@ -30,7 +30,7 @@ module Compass if top_level.environment == :development :expanded else - :compact + :compressed end end From 28ccff0fba5e99dcd9895f16726473cb8a3bf545 Mon Sep 17 00:00:00 2001 From: Chris Eppstein Date: Sun, 24 Apr 2011 20:04:03 -0700 Subject: [PATCH 3/3] Make the generated configuration file a little more readable. --- lib/compass/configuration/serialization.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/compass/configuration/serialization.rb b/lib/compass/configuration/serialization.rb index 3e7fcc80..ff41ecc2 100644 --- a/lib/compass/configuration/serialization.rb +++ b/lib/compass/configuration/serialization.rb @@ -50,6 +50,7 @@ module Compass $stderr.puts "WARNING: #{prop} is code and cannot be written to a file. You'll need to copy it yourself." end if respond_to?("comment_for_#{prop}") + contents << "\n" contents << send("comment_for_#{prop}") end if block_given? && (to_emit = yield(prop, value))