4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
# File 'lib/compass/commands/help.rb', line 4
def set_options(opts)
banner = %Q{Usage: compass help [command]
Description:
The Compass Stylesheet Authoring Framework helps you
build and maintain your stylesheets and makes it easy
for you to use stylesheet libraries provided by others.
To get help on a particular command please specify the command.
}
primary_commands = Compass::Commands.all.select do |c|
cmd = Compass::Commands[c]
cmd.respond_to?(:primary) && cmd.primary
end
other_commands = Compass::Commands.all - primary_commands
banner << command_list("Primary Commands:", primary_commands)
banner << command_list("Other Commands:", other_commands)
banner << "\nAvailable Frameworks & Patterns:\n\n"
Compass::Frameworks::ALL.each do |framework|
banner << " * #{framework.name}\n"
framework.template_directories.each do |pattern|
banner << " - #{framework.name}/#{pattern}"
if description = framework.manifest(pattern).description
banner << "\t- #{description}"
end
banner << "\n"
end
end
opts.banner = banner
super
end
|