Sha256: 3c23a2957f6fbe1ea79745a8850036fae9dfd698107861eb24c390427f4a4bb7

Contents?: true

Size: 1.32 KB

Versions: 17

Compression:

Stored size: 1.32 KB

Contents

$:.unshift('.') # 1.9.2

require 'rubygems'
require 'rubygems/user_interaction' if Gem::RubyGemsVersion == '1.5.0'

require 'rake'
require 'rake/clean'
#require 'rake/rdoctask'
require 'rdoc/task'


#
# clean

CLEAN.include('pkg', 'rdoc')


#
# test / spec

#task :spec => :check_dependencies do
task :spec do
  exec 'rspec spec/'
end
task :test => :spec

task :default => :spec


#
# gem

GEMSPEC_FILE = Dir['*.gemspec'].first
GEMSPEC = eval(File.read(GEMSPEC_FILE))
GEMSPEC.validate


desc %{
  builds the gem and places it in pkg/
}
task :build do

  sh "gem build #{GEMSPEC_FILE}"
  sh "mkdir pkg" rescue nil
  sh "mv #{GEMSPEC.name}-#{GEMSPEC.version}.gem pkg/"
end

desc %{
  builds the gem and pushes it to rubygems.org
}
task :push => :build do

  sh "gem push pkg/#{GEMSPEC.name}-#{GEMSPEC.version}.gem"
end


#
# rdoc
#
# make sure to have rdoc 2.5.x to run that

Rake::RDocTask.new do |rd|

  rd.main = 'README.txt'
  rd.rdoc_dir = "rdoc/#{GEMSPEC.name}"

  rd.rdoc_files.include('README.rdoc', 'CHANGELOG.txt', 'lib/**/*.rb')

  rd.title = "#{GEMSPEC.name} #{GEMSPEC.version}"
end


#
# upload_rdoc

desc %{
  upload the rdoc to rubyforge
}
task :upload_rdoc => [ :clean, :rdoc ] do

  account = 'jmettraux@rubyforge.org'
  webdir = '/var/www/gforge-projects/rufus'

  sh "rsync -azv -e ssh rdoc/#{GEMSPEC.name} #{account}:#{webdir}/"
end

Version data entries

17 entries across 17 versions & 3 rubygems

Version Path
rufus-scheduler-2.0.24 Rakefile
rufus-scheduler-2.0.23 Rakefile
rufus-scheduler-2.0.22 Rakefile
rufus-scheduler-2.0.21 Rakefile
rufus-scheduler-2.0.20 Rakefile
rufus-scheduler-2.0.19 Rakefile
rufus-scheduler-2.0.18 Rakefile
rufus-scheduler-2.0.17 Rakefile
rufus-lru-1.0.5 Rakefile
rufus-lru-1.0.4 Rakefile
rufus-verbs-1.0.1 Rakefile
rufus-scheduler-2.0.16 Rakefile
rufus-scheduler-2.0.15 Rakefile
rufus-scheduler-2.0.14 Rakefile
rufus-scheduler-2.0.13 Rakefile
rufus-scheduler-2.0.12 Rakefile
rufus-scheduler-2.0.11 Rakefile