Permalink
Browse files

add a modern gemspec

  • Loading branch information...
1 parent 1a598d2 commit 6c694d26b1d10733ea24164e284534d3e2128cea @atmos atmos committed May 16, 2011
Showing with 32 additions and 46 deletions.
  1. +0 −46 Rakefile
  2. +32 −0 warden-github.gemspec
View
@@ -13,50 +13,4 @@ Spec::Rake::SpecTask.new do |t|
t.spec_files = FileList['spec/**/*_spec.rb']
t.spec_opts = %w(-fs --color)
t.spec_opts << '--loadby' << 'random'
-
- t.rcov_opts << '--exclude' << 'spec,.bundle,.rvm'
- t.rcov = ENV.has_key?('NO_RCOV') ? ENV['NO_RCOV'] != 'true' : true
- t.rcov_opts << '--text-summary'
- t.rcov_opts << '--sort' << 'coverage' << '--sort-reverse'
-end
-
-GEM = "warden-github"
-GEM_VERSION = Warden::Github::VERSION
-AUTHOR = "Corey Donohoe"
-EMAIL = "atmos@atmos.org"
-HOMEPAGE = "http://github.com/atmos/warden-github"
-SUMMARY = "A warden extension that integrates with github oauth"
-
-spec = Gem::Specification.new do |s|
- s.name = GEM
- s.version = GEM_VERSION
- s.platform = Gem::Platform::RUBY
- s.has_rdoc = true
- s.extra_rdoc_files = ["LICENSE"]
- s.summary = SUMMARY
- s.description = s.summary
- s.author = AUTHOR
- s.email = EMAIL
- s.homepage = HOMEPAGE
-
- bundle = Bundler::Definition.build('Gemfile', 'Gemfile.lock', { })
- bundle.dependencies.each do |dep|
- next unless dep.groups.include?(:runtime)
- s.add_dependency(dep.name, dep.version_requirements.to_s)
- end
-
- s.require_path = 'lib'
- s.files = %w(LICENSE README.md) + Dir.glob("{lib}/**/*")
end
-
-Rake::GemPackageTask.new(spec) do |pkg|
- pkg.gem_spec = spec
-end
-
-desc "create a gemspec file"
-task :make_spec do
- File.open("#{GEM}.gemspec", "w") do |file|
- file.puts spec.to_ruby
- end
-end
-
View
@@ -0,0 +1,32 @@
+# -*- encoding: utf-8 -*-
+$:.push File.expand_path("../lib", __FILE__)
+
+Gem::Specification.new do |s|
+ s.name = "warden-github"
+ s.version = "0.0.8"
+ s.platform = Gem::Platform::RUBY
+ s.authors = ["Corey Donohoe"]
+ s.email = ["atmos@atmos.org"]
+ s.homepage = "http://github.com/atmos/warden-github"
+ s.summary = "A warden strategy for easy oauth integration with github"
+ s.description = s.summary
+
+ s.rubyforge_project = "warden-github"
+
+ s.add_dependency "json", "~>1.5"
+ s.add_dependency "warden", "~>1.0.4"
+ s.add_dependency "oauth2", "~>0.4.1"
+
+ s.add_development_dependency "rake"
+ s.add_development_dependency "rspec", "~>1.3.0"
+ s.add_development_dependency "shotgun"
+ s.add_development_dependency "bundler", "~>1.0"
+ s.add_development_dependency "addressable", "~>2.2.0"
+ s.add_development_dependency "rack-test", "~>0.5.3"
+ s.add_development_dependency "ruby-debug"
+
+ s.files = `git ls-files`.split("\n")
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
+ s.require_paths = ["lib"]
+end

0 comments on commit 6c694d2

Please sign in to comment.