diff --git a/doc-src/content/CHANGELOG.markdown b/doc-src/content/CHANGELOG.markdown index 3e4cebe8..ab57d09b 100644 --- a/doc-src/content/CHANGELOG.markdown +++ b/doc-src/content/CHANGELOG.markdown @@ -7,6 +7,11 @@ layout: article COMPASS CHANGELOG ================= +0.10.1 (May 13, 2010) +--------------------- + +* Added a subcommand for emitting sass imports for the sass CLI. + 0.10.0 (May 10, 2010) --------------------- diff --git a/lib/compass/commands.rb b/lib/compass/commands.rb index ce22e296..1d59e60c 100644 --- a/lib/compass/commands.rb +++ b/lib/compass/commands.rb @@ -4,7 +4,7 @@ end require 'compass/commands/registry' %w(base generate_grid_background help list_frameworks project_base - update_project watch_project create_project installer_command + update_project watch_project create_project imports installer_command print_version project_stats stamp_pattern validate_project write_configuration interactive).each do |lib| require "compass/commands/#{lib}" diff --git a/lib/compass/commands/imports.rb b/lib/compass/commands/imports.rb new file mode 100644 index 00000000..24505258 --- /dev/null +++ b/lib/compass/commands/imports.rb @@ -0,0 +1,29 @@ +module Compass + module Commands + class Imports < ProjectBase + attr_accessor :options + register :imports + def initialize(working_path, options) + super + end + + def execute + print ::Compass::Frameworks::ALL.map{|f| + "-I #{f.stylesheets_directory}" + }.join(' ') + end + class << self + def description(command) + "Emit an imports suitable for passing to the sass command-line." + end + def parse!(arguments) + if arguments.join("").strip.size > 0 + raise OptionParser::ParseError, "This command takes no options or arguments." + else + {} + end + end + end + end + end +end