X-Git-Url: http://git.code-monkey.de/?a=blobdiff_plain;f=Rakefile;h=c801ae961b06e0da7cae80689dea9bea3dbb3899;hb=20af3a3a8e6dd1eb5cd7676f907165dfa05e804f;hp=3e47175a8ecd41c0e3a528d8b37b459955aa6964;hpb=07b4660cebea81f31bfa0b47981a7e06fe35ef1f;p=redact.git diff --git a/Rakefile b/Rakefile index 3e47175..c801ae9 100644 --- a/Rakefile +++ b/Rakefile @@ -1,5 +1,3 @@ -# $Id: Rakefile 34 2005-04-25 17:12:29Z tilman $ - require "rake/clean" require "rake/testtask" require "rake/rdoctask" @@ -16,19 +14,19 @@ PKG_NAME = "redact" PKG_VERSION = File.read("lib/redact/redact.rb"). match(/^\s*VERSION = \"(.*)\"\s*$/).captures.first -CLOBBER.include(FileList["test/*.edj"]) - -sitelibdir = Config::CONFIG["sitelibdir"] -destdir = "#{ENV["DESTDIR"]}" -prefix = ENV["PREFIX"] || "/usr/local" +CLOBBER.include("test/*.edj") task :install do |t| + sitelibdir = Config::CONFIG["sitelibdir"] + destdir = "#{ENV["DESTDIR"]}" + prefix = ENV["PREFIX"] || "/usr/local" + ddir = destdir + prefix + "/bin" FileUtils::Verbose.install("bin/redact", ddir, :mode => 0755) ddir = destdir + sitelibdir + "/redact" - FileUtils::Verbose.mkdir(ddir) unless File.directory?(ddir) + FileUtils::Verbose.mkdir_p(ddir) unless File.directory?(ddir) FileUtils::Verbose.install(Dir["lib/redact/*.rb"], ddir, :mode => 0644) end @@ -45,21 +43,29 @@ Rake::RDocTask.new do |t| t.rdoc_dir = "doc" t.title = "Redact - An Edje Compiler written in Ruby" t.options = ["--line-numbers", "--inline-source", "--main", "README"] - t.rdoc_files.include("README", "COPYING", "AUTHORS", "ChangeLog", + t.rdoc_files.include("README", "COPYING", "AUTHORS", "TODO", "NEWS", "lib/redact/redact.rb", "lib/redact/part.rb", "lib/redact/program.rb") end +CLOBBER.include("ChangeLog") + +file "ChangeLog" do + `git log > ChangeLog` +end + Rake::PackageTask.new(PKG_NAME, PKG_VERSION) do |t| t.need_tar_gz = true - t.package_files.include("[A-Z]*", "bin/redact", "lib/redact/*.rb", + t.package_files.include("AUTHORS", "COPYING", "ChangeLog", "NEWS", + "README", "Rakefile", "TODO", + "bin/redact", "lib/redact/*.rb", "test/*.rb") end task :publish => [:rdoc, :package] do p = Rake::CompositePublisher.new p.add(Rake::SshFreshDirPublisher.new("code-monkey.de", - "public_html/docs/" + + "public_docs/" + PKG_NAME, "doc")) p.add(Rake::SshFilePublisher.new("code-monkey.de", ".", "pkg",