exe/chutney in chutney-3.0.0.beta.2 vs exe/chutney in chutney-3.0.0
- old
+ new
@@ -10,27 +10,27 @@
formatters = Set.new
OptionParser.new do |opts|
opts.banner = 'Usage: chutney [files]'
- opts.on('-f',
- '--format [formatter]',
+ opts.on('-f',
+ '--format [formatter]',
'One of JSONFormatter, PieFormatter or RainbowFormatter (default).') do |formatter|
raise 'No Such Formatter' unless %w[JSONFormatter PieFormatter RainbowFormatter].include? formatter
formatters << formatter
end
-
+
opts.on('-l',
'--linters',
'List the linter status by this configuration and exit') do
pastel = Pastel.new
chutney_config = Chutney::ChutneyLint.new.configuration
max_name_length = chutney_config.keys.map(&:length).max + 1
chutney_config.each do |linter, value|
print pastel.cyan(linter.ljust(max_name_length))
-
+
if value['Enabled']
puts pastel.green('enabled')
else
puts pastel.red('disabled')
end
@@ -40,10 +40,10 @@
end.parse!
formatters << 'RainbowFormatter' if formatters.empty?
files = ARGV.map { |pattern| Dir.glob(pattern) }.flatten
-files = Dir.glob('features/**/*.feature') if ARGV.empty?
+files = Dir.glob('features/**/*.feature') if ARGV.empty?
linter = Chutney::ChutneyLint.new(*files)
report = linter.analyse
formatters.each do |formatter|