Sha256: 82bd7b43b20731dcd4d5bc24b1292f2154e886a500617d410e999033101698c7
Contents?: true
Size: 1.59 KB
Versions: 1
Compression:
Stored size: 1.59 KB
Contents
require "rake/rdoctask" require "yaml" GEM_NAME = "irb_hacks" begin require "jeweler" Jeweler::Tasks.new do |gem| gem.name = GEM_NAME gem.summary = "Yet another set of IRB hacks" gem.description = "Yet another set of IRB hacks" gem.email = "alex.r@askit.org" gem.homepage = "http://github.com/dadooda/irb_hacks" gem.authors = ["Alex Fortuna"] gem.files = FileList[ "[A-Z]*", "*.gemspec", "lib/**/*.rb", ] end rescue LoadError STDERR.puts "This gem requires Jeweler to be built" end desc "Rebuild gemspec and package" task :rebuild => [:gemspec, :build] desc "Push (publish) gem to RubyGems.org" task :push do # Yet found no way to ask Jeweler forge a complete version string for us. vh = YAML.load(File.read("VERSION.yml")) version = [vh[:major], vh[:minor], vh[:patch], (if (v = vh[:build]); v; end)].compact.join(".") pkgfile = File.join("pkg", [GEM_NAME, "-", version, ".gem"].join) Kernel.system("gem", "push", pkgfile) end desc "Generate RDoc documentation" Rake::RDocTask.new(:rdoc) do |rdoc| rdoc.rdoc_dir = "doc" rdoc.title = "IrbHacks" #rdoc.options << "--line-numbers" #rdoc.options << "--inline-source" rdoc.rdoc_files.include("lib/**/*.rb") end #Rake::GemPackageTask.new(spec) do |p| # p.need_tar = true if RUBY_PLATFORM !~ /mswin/ #end desc "Compile README preview" task :readme do require "kramdown" doc = Kramdown::Document.new(File.read "README.md") fn = "README.html" puts "Writing '#{fn}'..." File.open(fn, "w") do |f| f.write(File.read "dev/head.html") f.write(doc.to_html) end puts ": ok" end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
irb_hacks-0.2.2 | Rakefile |