From 250cf8c1b2256d3f6f10992f8719de55c56454bd Mon Sep 17 00:00:00 2001 From: Sergio Rubio Date: Fri, 18 Jan 2013 20:32:54 +0100 Subject: [PATCH] Added some task descriptions so they show up with 'rake -T' I guess it does no harm to have some additional task descriptions and help our memory. Before: rake changelog # Update the changelog since the last release rake console # Open an irb session preloaded with this library rake test # Run the mocked tests rake yard # Generate YARD Documentation Now: rake build # Build fog-1.8.0.gem rake changelog # Update the changelog since the last release rake console # Open an irb session preloaded with this library rake gemspec # Updates the gemspec and runs 'validate' rake test # Run the mocked tests rake validate # Run before pushing out the code rake yard # Generate YARD Documentation --- Rakefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Rakefile b/Rakefile index 6990b11e2..91738ed09 100644 --- a/Rakefile +++ b/Rakefile @@ -135,12 +135,14 @@ task :gem_push do sh "gem push pkg/#{name}-#{version}.gem" end +desc "Build fog-#{version}.gem" task :build => :gemspec do sh "mkdir -p pkg" sh "gem build #{gemspec_file}" sh "mv #{gem_file} pkg" end +desc "Updates the gemspec and runs 'validate'" task :gemspec => :validate do # read spec file and split out manifest section spec = File.read(gemspec_file) @@ -156,6 +158,7 @@ task :gemspec => :validate do puts "Updated #{gemspec_file}" end +desc "Run before pushing out the code" task :validate do libfiles = Dir['lib/*'] - ["lib/#{name}.rb", "lib/#{name}", "lib/tasks"] unless libfiles.empty?