Rakefile in random_text-1.0.2 vs Rakefile in random_text-1.0.2.1

- old
+ new

@@ -1,28 +1,25 @@ -begin - require 'jeweler' +require 'rake' +require 'jeweler' +require 'rake/gem_ghost_task' +require 'rspec/core/rake_task' - name = 'random_text' - summary = 'Library to generate random strings' +name = 'random_text' - jewel = Jeweler::Tasks.new do |j| - j.name = name - j.summary = summary - j.homepage = "http://github.com/toy/#{name}" - j.authors = ["Boba Fat"] - end +Jeweler::Tasks.new do |gem| + gem.name = name + gem.summary = %Q{Library to generate random strings} + gem.homepage = "http://github.com/toy/#{name}" + gem.license = 'MIT' + gem.authors = ['Ivan Kuchin'] + gem.add_development_dependency 'jeweler', '~> 1.5.1' + gem.add_development_dependency 'rake-gem-ghost' + gem.add_development_dependency 'rspec' +end +Jeweler::RubygemsDotOrgTasks.new +Rake::GemGhostTask.new - Jeweler::GemcutterTasks.new - - require 'pathname' - desc "Replace system gem with symlink to this folder" - task 'ghost' do - gem_path = Pathname(Gem.searcher.find(name).full_gem_path) - current_path = Pathname('.').expand_path - cmd = gem_path.writable? && gem_path.parent.writable? ? %w() : %w(sudo) - system(*cmd + %W[rm -r #{gem_path}]) - system(*cmd + %W[ln -s #{current_path} #{gem_path}]) - end - -rescue LoadError - puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler" +RSpec::Core::RakeTask.new(:spec) do |spec| + spec.rspec_opts = ['--colour --format progress'] + spec.pattern = 'spec/**/*_spec.rb' end +task :default => :spec