From 9b1d99fd92b51fdba23e5d76ce413896cffbc03d Mon Sep 17 00:00:00 2001 From: "Mahlon E. Smith" Date: Sat, 22 Jan 2011 01:54:06 -0800 Subject: [PATCH] Update copyright, make description shorter so it'll look nicer when formatted on rubygems.org. --- .hgignore | 2 +- chunker/LICENSE | 2 +- chunker/Rakefile | 32 ++++++++------------------------ 3 files changed, 10 insertions(+), 26 deletions(-) diff --git a/.hgignore b/.hgignore index d7e224d..7752ff1 100644 --- a/.hgignore +++ b/.hgignore @@ -1 +1 @@ -^chunker/pkg +^chunker/(pkg|tags) diff --git a/chunker/LICENSE b/chunker/LICENSE index 3516f6f..001c7ef 100644 --- a/chunker/LICENSE +++ b/chunker/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2008, Mahlon E. Smith +Copyright (c) 2008-2011, Mahlon E. Smith All rights reserved. diff --git a/chunker/Rakefile b/chunker/Rakefile index 6e27262..e06fc49 100644 --- a/chunker/Rakefile +++ b/chunker/Rakefile @@ -65,6 +65,9 @@ task :test => 'test:spec' task :default => :test # task :default => [ :test, :package ] + +### Tasks: testing via rspec +### namespace :test do desc 'Generate verbose and pretty output' RSpec::Core::RakeTask.new( :spec ) do |task| @@ -79,6 +82,7 @@ namespace :test do end end + ### Task: generate ctags ### This assumes exuberant ctags, since ctags 'native' doesn't support ruby anyway. ### @@ -98,36 +102,16 @@ gem = Gem::Specification.new do |gem| gem.email = 'mahlon@martini.nu' gem.homepage = 'http://projects.martini.nu/ruby-modules/wiki/Chunker' gem.has_rdoc = true + gem.extra_rdoc_files = ['README'] + gem.rdoc_options << '--main' << 'README' + gem.files = RELEASE_FILES. collect {|f| f.relative_path_from(BASEDIR).to_s } gem.test_files = SPEC_FILES. collect {|f| f.relative_path_from(BASEDIR).to_s } - gem.description = <<-EOF - Ruby provides an automatic constant called DATA, which is an IO object - that references all text in the current file under an __END__ token. - - I find it convenient to use the __END__ area to store all sorts of - stuff, rather than have to worry about distributing separate files. - - The DATA constant is determined from whatever ruby believes $0 to be. - It doesn't work inside of other required libraries, so you'll see stuff - like this all the time: - - END = File.open( __FILE__ ).read.split( /^__END__/, 2 ).last - - It works, but it's more work than I want to do. - - Chunker solves this by parsing __END__ tokens for you, and making it - available in the form of a 'DATA_END' constant. It installs this - constant into the class that includes Chunker, so you can use it again - and again, assuming you use a different file for each class. - - It also automatically parses out other things that look like tokens, so - you can easily have multiple, distinct documents all embedded into the - __END__ block. - EOF + gem.description = "Embed arbitrary data and multiple, distinct documents within ruby files." end Rake::GemPackageTask.new( gem ) do |pkg|