From 3933282ddf86a70b94941ade736d3ad2830b8f93 Mon Sep 17 00:00:00 2001 From: "James A. Rosen" Date: Sat, 12 Jun 2010 21:29:31 -0400 Subject: [PATCH] using Bundler to declare dependencies --- .gitignore | 3 ++- Gemfile | 35 +++++++++++++++++++++++++++ Rakefile | 4 ++- oa-basic/Rakefile | 6 ++++- oa-core/Rakefile | 6 ++++- oa-core/spec/omniauth/builder_spec.rb | 4 +-- oa-oauth/Rakefile | 6 ++++- oa-openid/Rakefile | 6 ++++- omniauth/Rakefile | 4 ++- 9 files changed, 65 insertions(+), 9 deletions(-) create mode 100644 Gemfile diff --git a/.gitignore b/.gitignore index 7e0d7ad..7334a33 100644 --- a/.gitignore +++ b/.gitignore @@ -24,4 +24,5 @@ rdoc pkg ## PROJECT::SPECIFIC -*.gem \ No newline at end of file +*.gem +.bundle diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000..856a641 --- /dev/null +++ b/Gemfile @@ -0,0 +1,35 @@ +source "http://rubygems.org" + +gem 'rack', '~> 1.1.0' + +group :oa_basic, :oa_oauth do + gem 'json', '~> 1.4.3' + gem 'nokogiri', '~> 1.4.2' +end + +group :oa_basic do + gem 'rest-client', '~> 1.5.1', :require => 'restclient' +end + +group :oa_oauth do + gem 'oauth', '~> 0.4.0' + gem 'oauth2', '~> 0.0.8' +end + +group :oa_openid do + gem 'rack-openid', '~> 1.0.3', :require => 'rack/openid' +end + +group :development, :test do + gem 'rake' +end + +group :development do + gem 'mg', '~> 0.0.8' + gem 'term-ansicolor', :require => 'term/ansicolor' +end + +group :test do + gem 'rspec', '~> 1.3.0', :require => 'spec' + gem 'webmock', '~> 1.2.2' +end \ No newline at end of file diff --git a/Rakefile b/Rakefile index cd33839..2ce8ff3 100644 --- a/Rakefile +++ b/Rakefile @@ -1,4 +1,6 @@ require 'rubygems' +require 'bundler' +Bundler.setup require 'rake' require 'term/ansicolor' @@ -83,4 +85,4 @@ namespace :version do end end -task :default => :spec \ No newline at end of file +task :default => :spec diff --git a/oa-basic/Rakefile b/oa-basic/Rakefile index 515879f..4eba556 100644 --- a/oa-basic/Rakefile +++ b/oa-basic/Rakefile @@ -1,4 +1,8 @@ +ENV['BUNDLE_GEMFILE'] = File.expand_path('../../Gemfile', __FILE__) + require 'rubygems' +require 'bundler' +Bundler.setup(:default, :development, :test, :oa_basic) require 'rake' require 'mg' @@ -10,4 +14,4 @@ Spec::Rake::SpecTask.new(:spec) do |spec| spec.spec_files = FileList['spec/**/*_spec.rb'] end -task :default => :spec \ No newline at end of file +task :default => :spec diff --git a/oa-core/Rakefile b/oa-core/Rakefile index e855c63..f5667b6 100644 --- a/oa-core/Rakefile +++ b/oa-core/Rakefile @@ -1,4 +1,8 @@ +ENV['BUNDLE_GEMFILE'] = File.expand_path('../../Gemfile', __FILE__) + require 'rubygems' +require 'bundler' +Bundler.setup(:default, :development, :test) require 'rake' require 'mg' @@ -10,4 +14,4 @@ Spec::Rake::SpecTask.new(:spec) do |spec| spec.spec_files = FileList['spec/**/*_spec.rb'] end -task :default => :spec \ No newline at end of file +task :default => :spec diff --git a/oa-core/spec/omniauth/builder_spec.rb b/oa-core/spec/omniauth/builder_spec.rb index 0b3e34e..f6f6ab0 100644 --- a/oa-core/spec/omniauth/builder_spec.rb +++ b/oa-core/spec/omniauth/builder_spec.rb @@ -8,10 +8,10 @@ describe OmniAuth::Builder do provider :my_strategy end end - + it 'should also just accept a class' do class ::ExampleClass; end - + lambda{ OmniAuth::Builder.new(nil) do provider ::ExampleClass end }.should_not raise_error diff --git a/oa-oauth/Rakefile b/oa-oauth/Rakefile index 1fb9b47..8392a38 100644 --- a/oa-oauth/Rakefile +++ b/oa-oauth/Rakefile @@ -1,4 +1,8 @@ +ENV['BUNDLE_GEMFILE'] = File.expand_path('../../Gemfile', __FILE__) + require 'rubygems' +require 'bundler' +Bundler.setup(:default, :development, :test, :oa_oauth) require 'rake' require 'mg' @@ -10,4 +14,4 @@ Spec::Rake::SpecTask.new(:spec) do |spec| spec.spec_files = FileList['spec/**/*_spec.rb'] end -task :default => :spec \ No newline at end of file +task :default => :spec diff --git a/oa-openid/Rakefile b/oa-openid/Rakefile index e210e56..cba0298 100644 --- a/oa-openid/Rakefile +++ b/oa-openid/Rakefile @@ -1,4 +1,8 @@ +ENV['BUNDLE_GEMFILE'] = File.expand_path('../../Gemfile', __FILE__) + require 'rubygems' +require 'bundler' +Bundler.setup(:default, :development, :test, :oa_openid) require 'rake' require 'mg' @@ -10,4 +14,4 @@ Spec::Rake::SpecTask.new(:spec) do |spec| spec.spec_files = FileList['spec/**/*_spec.rb'] end -task :default => :spec \ No newline at end of file +task :default => :spec diff --git a/omniauth/Rakefile b/omniauth/Rakefile index bb62f5d..7a3f56f 100644 --- a/omniauth/Rakefile +++ b/omniauth/Rakefile @@ -1,4 +1,6 @@ require 'rubygems' +require 'bundler' +Bundler.setup(:default, :development, :test) require 'rake' require 'mg' @@ -10,4 +12,4 @@ Spec::Rake::SpecTask.new(:spec) do |spec| spec.spec_files = FileList['spec/**/*_spec.rb'] end -task :default => :spec \ No newline at end of file +task :default => :spec