Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prepare Rakefile and gemspec for release.
- Loading branch information
Hiroshi Nakamura
committed
May 14, 2011
1 parent
5200f36
commit af96ca8
Showing
2 changed files
with
52 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
require 'rake' | ||
require 'rake/testtask' | ||
require 'rake/rdoctask' | ||
|
||
task :default => :gem | ||
|
||
begin | ||
require 'rake/gempackagetask' | ||
require 'logger.gemspec' | ||
Rake::GemPackageTask.new(SPEC) do |pkg| | ||
pkg.need_zip = true | ||
pkg.need_tar = true | ||
end | ||
rescue LoadError | ||
end | ||
|
||
begin | ||
require 'rcov/rcovtask' | ||
Rcov::RcovTask.new("coverage") do |rcov| | ||
rcov.libs << 'lib' | ||
rcov.pattern = 'test/test_*.rb' | ||
end | ||
rescue LoadError | ||
end | ||
|
||
Rake::TestTask.new("test") do |test| | ||
test.libs << 'lib' | ||
test.warning = true | ||
test.pattern = 'test/test_*.rb' | ||
end | ||
|
||
Rake::RDocTask.new("doc") do |rdoc| | ||
load 'lib/logger.rb' | ||
rdoc.rdoc_dir = 'doc' | ||
rdoc.title = "Logger Library Document: Version #{Logger::VERSION}" | ||
rdoc.rdoc_files.include('lib/logger.rb') | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
require 'rubygems' | ||
SPEC = Gem::Specification.new do |s| | ||
require 'lib/logger.rb' | ||
s.name = "logger" | ||
s.version = Logger::VERSION | ||
s.date = "2011-05-14" | ||
s.author = "NAKAMURA, Hiroshi" | ||
s.email = "nahi@ruby-lang.org" | ||
s.homepage = "http://github.com/nahi/logger" | ||
s.platform = Gem::Platform::RUBY | ||
s.summary = "simple logging utility" | ||
s.files = ["README", "lib/logger.rb", "test/test_logger.rb", *Dir.glob("sample/*.rb")] | ||
s.require_path = "lib" | ||
s.has_rdoc = true | ||
end |