lib/relish/commands/push.rb in relish-0.3.0 vs lib/relish/commands/push.rb in relish-0.4.0
- old
+ new
@@ -5,13 +5,15 @@
module Relish
module Command
class Push < Base
- usage 'push <project>:<version>'
+ usage 'push <project>:<version> [path <path>]'
+ option :path, :default => Proc.new { 'features' }
desc 'push features to a project',
'<version> is optional',
+ '<path> is optional (defaults to ./features)',
'example: relish push rspec/rspec-core',
'example: relish push rspec/rspec-core:2.0'
command :default do
post files_as_tar_gz, project_params
end
@@ -64,11 +66,11 @@
end
stream.string
end
def files
- Dir["features/**/*.{feature,md,markdown}"] +
- Dir["features/**/.nav"]
+ Dir["#{path}/**/*.{feature,md,markdown}"] +
+ Dir["#{path}/**/.nav"]
end
end