diff --git a/lib/compass/exec/helpers.rb b/lib/compass/exec/helpers.rb index 11d31dd6..f1e8db1a 100644 --- a/lib/compass/exec/helpers.rb +++ b/lib/compass/exec/helpers.rb @@ -5,8 +5,10 @@ module Compass::Exec if Compass::Commands.command_exists? arguments.first SubCommandUI else - Compass::Logger.new.red do - Haml::Util.haml_warn "WARNING: This interface is deprecated. Please use the new subcommand interface.\nSee `compass help` for more information.\n" + unless arguments.include?("-h") || arguments.include?("--help") + Compass::Logger.new.red do + Haml::Util.haml_warn "WARNING: This interface is deprecated. Please use the new subcommand interface.\nSee `compass help` for more information.\n" + end end SwitchUI end diff --git a/lib/compass/exec/switch_ui.rb b/lib/compass/exec/switch_ui.rb index 77552d45..a17a65ee 100644 --- a/lib/compass/exec/switch_ui.rb +++ b/lib/compass/exec/switch_ui.rb @@ -89,6 +89,11 @@ END self.options[:pattern] = pattern end + opts.on('-h', '--help') do + self.options[:command] = :help + self.options[:help_command] = :help + end + opts.on('--write-configuration', "Write the current configuration to the configuration file.") do self.options[:command] = :write_configuration end