about summary refs log tree commit homepage
path: root/tdb.gemspec
diff options
context:
space:
mode:
Diffstat (limited to 'tdb.gemspec')
-rw-r--r--tdb.gemspec16
1 files changed, 7 insertions, 9 deletions
diff --git a/tdb.gemspec b/tdb.gemspec
index ddd7806..77da3c0 100644
--- a/tdb.gemspec
+++ b/tdb.gemspec
@@ -1,22 +1,20 @@
-ENV["VERSION"] or abort "VERSION= must be specified"
-manifest = File.readlines('.manifest').map! { |x| x.chomp! }
-require 'olddoc'
-extend Olddoc::Gemspec
-name, summary, title = readme_metadata
+manifest = File.exist?('.manifest') ?
+  IO.readlines('.manifest').map!(&:chomp!) : `git ls-files`.split("\n")
 
 Gem::Specification.new do |s|
   s.name = %q{tdb}
-  s.version = ENV["VERSION"].dup
+  s.version = (ENV['VERSION'] || '0.6.2').dup
   s.homepage = 'https://yhbt.net/ruby-tdb/'
   s.authors = ["Ruby tdb hackers"]
-  s.description = readme_description
+  s.description = File.read('README').split("\n\n")[1]
   s.email = %q{ruby-tdb@yhbt.net}
-  s.extra_rdoc_files = extra_rdoc_files(manifest)
+  s.extra_rdoc_files = IO.readlines('.document').map!(&:chomp!).keep_if do |f|
+    File.exist?(f)
+  end
   s.files = manifest
   s.summary = summary
   s.test_files = Dir['test/test_*.rb']
   s.extensions = %w(ext/tdb/extconf.rb)
-  s.add_development_dependency('olddoc', '~> 1.0')
   s.add_development_dependency('test-unit', '>= 2.0', '< 4.0')
   s.licenses = %w(LGPL-2.1+)
 end