diff --git a/lib/chunks/engines.rb b/lib/chunks/engines.rb
index d1163e52..79511236 100644
--- a/lib/chunks/engines.rb
+++ b/lib/chunks/engines.rb
@@ -72,8 +72,6 @@ module Engines
my_content.to_s5
else
(t = Time.now; nil)
- puts "text is #{text.class}"
- puts "text responds to concat_with_safety" if text.respond_to?(:concat_with_safety)
html = Maruku.new(text,
{:math_enabled => true,
:math_numbered => ['\\[','\\begin{equation}']}).to_html
diff --git a/lib/sanitizer.rb b/lib/sanitizer.rb
index eecc924a..510d9341 100644
--- a/lib/sanitizer.rb
+++ b/lib/sanitizer.rb
@@ -9,6 +9,7 @@ module Sanitizer
require 'node'
require 'instiki_stringsupport'
require 'set'
+ require 'nokogiri'
acceptable_elements = Set.new %w[a abbr acronym address area article aside
audio b big blockquote br button canvas caption center cite code
@@ -227,9 +228,9 @@ module Sanitizer
# (REXML trees are always utf-8 encoded.)
def safe_xhtml_sanitize(html, options = {})
sanitized = xhtml_sanitize(html.purify)
- doc = REXML::Document.new("
(.*)<\/div>\Z/m, '\1')
- rescue REXML::ParseException
+ doc = Nokogiri::XML::Document.parse("
#{sanitized}
", nil, (options[:encoding] || 'UTF-8'), 0)
+ sanitized = doc.root.children.to_xml(:indent => (options[:indent] || 2), :save_with => 2 )
+ rescue Nokogiri::XML::SyntaxError
sanitized = sanitized.escapeHTML
end
diff --git a/test/unit/chunks/nowiki_test.rb b/test/unit/chunks/nowiki_test.rb
index f9b1ff0c..bbd00856 100755
--- a/test/unit/chunks/nowiki_test.rb
+++ b/test/unit/chunks/nowiki_test.rb
@@ -26,19 +26,27 @@ class NoWikiTest < Test::Unit::TestCase
def test_sanitize_nowiki
match(NoWiki, 'This sentence contains
[[test]]&shebang *foo*. Do not touch!',
- :plain_text => "[[test]]&
shebang <script>alert("xss!");</script> *foo*"
+ :plain_text => "[[test]]&
shebang <script>alert(\"xss!\");</script> *foo*"
)
end
+# Here, the input is not namespace-well-formed, but the output is.
+# I think that's OK.
def test_sanitize_nowiki_ill_formed
match(NoWiki, "
",
- :plain_text => "<animateColor xlink:href='#foo'/>"
+ :plain_text => '
'
)
end
def test_sanitize_nowiki_ill_formed_II
match(NoWiki, "
\000",
- :plain_text => %(<animateColor xlink:href='#foo'/>)
+ :plain_text => '
'
+ )
+ end
+
+ def test_sanitize_nowiki_ill_formed_III
+ match(NoWiki, "
\000",
+ :plain_text => '
'
)
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-benchmark b/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-benchmark
deleted file mode 100644
index 6673a878..00000000
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-benchmark
+++ /dev/null
@@ -1,19 +0,0 @@
-.\" generated with Ronn/v0.7.3
-.\" http://github.com/rtomayko/ronn/tree/0.7.3
-.
-.TH "BUNDLE\-BENCHMARK" "1" "May 2011" "" ""
-.
-.SH "NAME"
-\fBbundle\-benchmark\fR \- Display the time taken for each gem to be loaded
-.
-.SH "SYNOPSIS"
-\fBbundle benchmark\fR [group]
-.
-.SH "DESCRIPTION"
-This command loads all your required dependencies as per Bundler\.setup, and displays the total time spent in requiring each gem and its dependencies\.
-.
-.P
-Use this command to track down problems with excessive boot time in your application, or to optimize specific groups in your Gemfile for fast setup\.
-.
-.SH "GROUP OPTION"
-To test the load times for gems in a specific group, pass the group as an argument to \fBbundle benchmark\fR\. Omitting this option loads all dependencies in your Gemfile\.
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-benchmark.txt b/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-benchmark.txt
deleted file mode 100644
index 52b2a36c..00000000
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-benchmark.txt
+++ /dev/null
@@ -1,27 +0,0 @@
-BUNDLE-BENCHMARK(1) BUNDLE-BENCHMARK(1)
-
-
-
-NAME
- bundle-benchmark - Display the time taken for each gem to be loaded
-
-SYNOPSIS
- bundle benchmark [group]
-
-DESCRIPTION
- This command loads all your required dependencies as per Bundler.setup,
- and displays the total time spent in requiring each gem and its depen-
- dencies.
-
- Use this command to track down problems with excessive boot time in
- your application, or to optimize specific groups in your Gemfile for
- fast setup.
-
-GROUP OPTION
- To test the load times for gems in a specific group, pass the group as
- an argument to bundle benchmark. Omitting this option loads all depen-
- dencies in your Gemfile.
-
-
-
- May 2011 BUNDLE-BENCHMARK(1)
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/Rakefile.tt b/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/Rakefile.tt
deleted file mode 100644
index c702cfcc..00000000
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/Rakefile.tt
+++ /dev/null
@@ -1 +0,0 @@
-require 'bundler/gem_tasks'
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/version.rb b/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/version.rb
deleted file mode 100755
index b3efbb53..00000000
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/version.rb
+++ /dev/null
@@ -1,3 +0,0 @@
-class Thor
- VERSION = "0.14.0".freeze
-end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/pack/gems_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.15/spec/pack/gems_spec.rb
deleted file mode 100644
index 9b67cd25..00000000
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/pack/gems_spec.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-require "spec_helper"
-
-describe "bundle pack with gems" do
- describe "when there are only gemsources" do
- before :each do
- gemfile <<-G
- gem 'rack'
- G
-
- system_gems "rack-1.0.0"
- bundle :pack
- end
-
- it "locks the gemfile" do
- bundled_app("Gemfile.lock").should exist
- end
-
- it "caches the gems" do
- bundled_app("vendor/cache/rack-1.0.0.gem").should exist
- end
- end
-end
\ No newline at end of file
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/.gitignore b/vendor/plugins/bundler/gems/bundler-1.0.18/.gitignore
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/.gitignore
rename to vendor/plugins/bundler/gems/bundler-1.0.18/.gitignore
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/CHANGELOG.md b/vendor/plugins/bundler/gems/bundler-1.0.18/CHANGELOG.md
similarity index 95%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/CHANGELOG.md
rename to vendor/plugins/bundler/gems/bundler-1.0.18/CHANGELOG.md
index e9176ca1..d3af3c3e 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/CHANGELOG.md
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/CHANGELOG.md
@@ -1,3 +1,45 @@
+## 1.0.18 (Aug 16, 2011)
+
+Bugfixes:
+
+ - Fix typo in DEBUG_RESOLVER (@geemus)
+ - Fixes rake 0.9.x warning (@mtylty, #1333)
+
+Features:
+
+ - Run the bundle install earlier in a Capistrano deployment (@cgriego, #1300)
+ - Support hidden gemspec (@trans, @cldwalker, #827)
+ - Make fetch_specs faster (@zeha, #1294)
+ - Allow overriding development deps loaded by #gemspec (@lgierth, #1245)
+
+## 1.0.17 (Aug 8, 2011)
+
+Bugfixes:
+
+ - Fix rake issues with rubygems 1.3.x (#1342)
+ - Fixed invalid byte sequence error while installing gem on Ruby 1.9 (#1341)
+
+## 1.0.16 (Aug 8, 2011)
+
+Features:
+
+ - Performance fix for MRI 1.9 (@efficientcloud, #1288)
+ - Shortcuts (like `bundle i`) for all commands (@amatsuda)
+ - Correcly identify missing child dependency in error message
+
+Bugfixes:
+
+ - Allow Windows network share paths with forward slashes (@mtscout6, #1253)
+ - Check for rubygems.org credentials so `rake release` doesn't hang (#980)
+ - Find cached prerelease gems on rubygems 1.3.x (@dburt, #1202)
+ - Fix `bundle install --without` on kiji (@tmm1, #1287)
+ - Get rid of warning in ruby 1.9.3 (@smartinez87, #1231)
+
+Documentation:
+
+ - Documentation for `gem ..., :require => false` (@kmayer, #1292)
+ - Gems provide "executables", they are rarely also binaries (@fxn, #1242)
+
## 1.0.15 (June 9, 2011)
Features:
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/ISSUES.md b/vendor/plugins/bundler/gems/bundler-1.0.18/ISSUES.md
similarity index 96%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/ISSUES.md
rename to vendor/plugins/bundler/gems/bundler-1.0.18/ISSUES.md
index b1220dad..b60b42b6 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/ISSUES.md
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/ISSUES.md
@@ -50,6 +50,7 @@ Instructions that allow the Bundler team to reproduce your issue are vitally imp
- What version of Rubygems you are using (run `gem -v`)
- Whether you are using RVM, and if so what version (run `rvm -v`)
- Whether you have the `rubygems-bundler` gem, which can break gem binares
+ - Whether you have the `open_gem` gem, which can cause rake activation conflicts
If you are using Rails 2.3, please also include:
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/LICENSE b/vendor/plugins/bundler/gems/bundler-1.0.18/LICENSE
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/LICENSE
rename to vendor/plugins/bundler/gems/bundler-1.0.18/LICENSE
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/README.md b/vendor/plugins/bundler/gems/bundler-1.0.18/README.md
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/README.md
rename to vendor/plugins/bundler/gems/bundler-1.0.18/README.md
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/Rakefile b/vendor/plugins/bundler/gems/bundler-1.0.18/Rakefile
similarity index 96%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/Rakefile
rename to vendor/plugins/bundler/gems/bundler-1.0.18/Rakefile
index b07d399e..f01e54e4 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/Rakefile
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/Rakefile
@@ -40,9 +40,9 @@ begin
end
namespace :rubygems do
- # Rubygems 1.3.5, 1.3.6, and HEAD specs
+ # Rubygems specs by version
rubyopt = ENV["RUBYOPT"]
- %w(master v1.3.6 v1.3.7 v1.4.2 v1.5.3 v1.6.2 v1.7.2 v1.8.3).each do |rg|
+ %w(master v1.3.6 v1.3.7 v1.4.2 v1.5.3 v1.6.2 v1.7.2 v1.8.7).each do |rg|
desc "Run specs with Rubygems #{rg}"
RSpec::Core::RakeTask.new(rg) do |t|
t.rspec_opts = %w(-fs --color)
@@ -95,7 +95,7 @@ begin
raise "RVM is not available" unless File.exist?(File.expand_path("~/.rvm/scripts/rvm"))
end
- %w(1.8.6-p399 1.8.7-p302 1.9.2-p0).each do |ruby|
+ %w(1.8.6-p420 1.8.7-p334 1.9.2-p180).each do |ruby|
ruby_cmd = File.expand_path("~/.rvm/bin/ruby-#{ruby}")
desc "Run specs on Ruby #{ruby}"
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/UPGRADING.md b/vendor/plugins/bundler/gems/bundler-1.0.18/UPGRADING.md
similarity index 96%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/UPGRADING.md
rename to vendor/plugins/bundler/gems/bundler-1.0.18/UPGRADING.md
index 905f6a41..666dcf7a 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/UPGRADING.md
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/UPGRADING.md
@@ -61,8 +61,8 @@ Bundler 0.9 removes the following Bundler 0.8 Gemfile APIs:
via `bundle install /path/to/bundle`. Bundler will remember
where you installed the dependencies to on a particular
machine for future installs, loads, setups, etc.
-5. `bin_path`: Bundler no longer generates binaries in the root
- of your app. You should use `bundle exec` to execute binaries
+5. `bin_path`: Bundler no longer generates executables in the root
+ of your app. You should use `bundle exec` to execute executables
in the current context.
### Gemfile Changes
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/bin/bundle b/vendor/plugins/bundler/gems/bundler-1.0.18/bin/bundle
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/bin/bundle
rename to vendor/plugins/bundler/gems/bundler-1.0.18/bin/bundle
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/bundler.gemspec b/vendor/plugins/bundler/gems/bundler-1.0.18/bundler.gemspec
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/bundler.gemspec
rename to vendor/plugins/bundler/gems/bundler-1.0.18/bundler.gemspec
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/capistrano.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/capistrano.rb
similarity index 88%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/capistrano.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/capistrano.rb
index 0a14c6d8..dc551c50 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/capistrano.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/capistrano.rb
@@ -5,7 +5,7 @@
require 'bundler/deployment'
Capistrano::Configuration.instance(:must_exist).load do
- after "deploy:update_code", "bundle:install"
+ after "deploy:finalize_update", "bundle:install"
Bundler::Deployment.define_task(self, :task, :except => { :no_release => true })
set :rake, lambda { "#{fetch(:bundle_cmd, "bundle")} exec rake" }
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/cli.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/cli.rb
similarity index 98%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/cli.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/cli.rb
index 5df8af8d..3c8dee0b 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/cli.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/cli.rb
@@ -1,6 +1,4 @@
-$:.unshift File.expand_path('../vendor', __FILE__)
-require 'thor'
-require 'thor/actions'
+require 'bundler/vendored_thor'
require 'rubygems/user_interaction'
require 'rubygems/config_file'
@@ -16,7 +14,7 @@ module Bundler
Bundler.rubygems.ui = UI::RGProxy.new(Bundler.ui)
end
- check_unknown_options! unless ARGV.include?("exec") || ARGV.include?("config")
+ check_unknown_options!
default_task :install
class_option "no-color", :type => :boolean, :banner => "Disable colorization in output"
@@ -154,10 +152,10 @@ module Bundler
opts = options.dup
opts[:without] ||= []
if opts[:without].size == 1
- opts[:without].map!{|g| g.split(" ") }
+ opts[:without] = opts[:without].map{|g| g.split(" ") }
opts[:without].flatten!
end
- opts[:without].map!{|g| g.to_sym }
+ opts[:without] = opts[:without].map{|g| g.to_sym }
# Can't use Bundler.settings for this because settings needs gemfile.dirname
ENV['BUNDLE_GEMFILE'] = File.expand_path(opts[:gemfile]) if opts[:gemfile]
@@ -349,7 +347,7 @@ module Bundler
exit 126
rescue Errno::ENOENT
Bundler.ui.error "bundler: command not found: #{ARGV.first}"
- Bundler.ui.warn "Install missing gem binaries with `bundle install`"
+ Bundler.ui.warn "Install missing gem executables with `bundle install`"
exit 127
end
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/definition.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/definition.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/definition.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/definition.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/dependency.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/dependency.rb
similarity index 97%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/dependency.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/dependency.rb
index e05b85a8..cb5709d1 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/dependency.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/dependency.rb
@@ -24,7 +24,8 @@ module Bundler
}.freeze
def initialize(name, version, options = {}, &blk)
- super(name, version)
+ type = options["type"] || :runtime
+ super(name, version, type)
@autorequire = nil
@groups = Array(options["group"] || :default).map { |g| g.to_sym }
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/deployment.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/deployment.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/deployment.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/deployment.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/dsl.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/dsl.rb
similarity index 85%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/dsl.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/dsl.rb
index fa80a76d..2d4adaef 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/dsl.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/dsl.rb
@@ -22,7 +22,7 @@ module Bundler
def gemspec(opts = nil)
path = opts && opts[:path] || '.'
- name = opts && opts[:name] || '*'
+ name = opts && opts[:name] || '{,*}'
development_group = opts && opts[:development_group] || :development
path = File.expand_path(path, Bundler.default_gemfile.dirname)
gemspecs = Dir[File.join(path, "#{name}.gemspec")]
@@ -34,7 +34,7 @@ module Bundler
gem spec.name, :path => path
group(development_group) do
spec.development_dependencies.each do |dep|
- gem dep.name, *dep.requirement.as_list
+ gem dep.name, *(dep.requirement.as_list + [:type => :development])
end
end
when 0
@@ -57,20 +57,34 @@ module Bundler
dep = Dependency.new(name, version, options)
+ # if there's already a dependency with this name we try to prefer one
if current = @dependencies.find { |d| d.name == dep.name }
if current.requirement != dep.requirement
- raise DslError, "You cannot specify the same gem twice with different version requirements. " \
- "You specified: #{current.name} (#{current.requirement}) and " \
- "#{dep.name} (#{dep.requirement})"
+ if current.type == :development
+ @dependencies.delete current
+ elsif dep.type == :development
+ return
+ else
+ raise DslError, "You cannot specify the same gem twice with different version requirements. " \
+ "You specified: #{current.name} (#{current.requirement}) and " \
+ "#{dep.name} (#{dep.requirement})"
+ end
end
if current.source != dep.source
- raise DslError, "You cannot specify the same gem twice coming from different sources. You " \
- "specified that #{dep.name} (#{dep.requirement}) should come from " \
- "#{current.source || 'an unspecfied source'} and #{dep.source}"
+ if current.type == :development
+ @dependencies.delete current
+ elsif dep.type == :development
+ return
+ else
+ raise DslError, "You cannot specify the same gem twice coming from different sources. You " \
+ "specified that #{dep.name} (#{dep.requirement}) should come from " \
+ "#{current.source || 'an unspecfied source'} and #{dep.source}"
+ end
end
end
- @dependencies << Dependency.new(name, version, options)
+
+ @dependencies << dep
end
def source(source, options = {})
@@ -183,7 +197,7 @@ module Bundler
def _normalize_options(name, version, opts)
_normalize_hash(opts)
- invalid_keys = opts.keys - %w(group groups git path name branch ref tag require submodules platform platforms)
+ invalid_keys = opts.keys - %w(group groups git path name branch ref tag require submodules platform platforms type)
if invalid_keys.any?
plural = invalid_keys.size > 1
message = "You passed #{invalid_keys.map{|k| ':'+k }.join(", ")} "
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/environment.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/environment.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/environment.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/environment.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/gem_helper.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/gem_helper.rb
similarity index 91%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/gem_helper.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/gem_helper.rb
index 474e8454..4f8cebcb 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/gem_helper.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/gem_helper.rb
@@ -16,7 +16,7 @@ module Bundler
def initialize(base, name = nil)
Bundler.ui = UI::Shell.new(Thor::Base.shell.new)
@base = base
- gemspecs = name ? [File.join(base, "#{name}.gemspec")] : Dir[File.join(base, "*.gemspec")]
+ gemspecs = name ? [File.join(base, "#{name}.gemspec")] : Dir[File.join(base, "{,*}.gemspec")]
raise "Unable to determine name from existing gemspec. Use :name => 'gemname' in #install_tasks to manually set it." unless gemspecs.size == 1
@spec_path = gemspecs.first
@gemspec = Bundler.load_gemspec(@spec_path)
@@ -41,7 +41,7 @@ module Bundler
def build_gem
file_name = nil
- sh("gem build '#{spec_path}'") { |out, code|
+ sh("gem build -V '#{spec_path}'") { |out, code|
raise out unless out[/Successfully/]
file_name = File.basename(built_gem_path)
FileUtils.mkdir_p(File.join(base, 'pkg'))
@@ -70,9 +70,12 @@ module Bundler
protected
def rubygem_push(path)
- out, _ = sh("gem push '#{path}'")
- raise "Gem push failed due to lack of RubyGems.org credentials." if out[/Enter your RubyGems.org credentials/]
- Bundler.ui.confirm "Pushed #{name} #{version} to rubygems.org"
+ if Pathname.new("~/.gem/credentials").expand_path.exist?
+ sh("gem push '#{path}'")
+ Bundler.ui.confirm "Pushed #{name} #{version} to rubygems.org"
+ else
+ raise "Your rubygems.org credentials aren't set. Run `gem push` to set them."
+ end
end
def built_gem_path
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/gem_tasks.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/gem_tasks.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/gem_tasks.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/gem_tasks.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/graph.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/graph.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/graph.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/graph.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/index.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/index.rb
similarity index 88%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/index.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/index.rb
index 4d7f7725..22b0f6fc 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/index.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/index.rb
@@ -78,10 +78,13 @@ module Bundler
end
end
- def use(other)
+ def use(other, override_dupes = false)
return unless other
other.each do |s|
- next if search_by_spec(s).any?
+ if (dupes = search_by_spec(s)) && dupes.any?
+ next unless override_dupes
+ @specs[s.name] -= dupes
+ end
@specs[s.name] << s
end
self
@@ -101,10 +104,15 @@ module Bundler
end
end
- def same_version?(a, b)
- regex = /^(.*?)(?:\.0)*$/
-
- a.to_s[regex, 1] == b.to_s[regex, 1]
+ if RUBY_VERSION < '1.9'
+ def same_version?(a, b)
+ regex = /^(.*?)(?:\.0)*$/
+ a.to_s[regex, 1] == b.to_s[regex, 1]
+ end
+ else
+ def same_version?(a, b)
+ a == b
+ end
end
def spec_satisfies_dependency?(spec, dep)
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/installer.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/installer.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/installer.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/installer.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/lazy_specification.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/lazy_specification.rb
similarity index 84%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/lazy_specification.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/lazy_specification.rb
index 5924ec60..e9d6b226 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/lazy_specification.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/lazy_specification.rb
@@ -58,13 +58,16 @@ module Bundler
private
+ def to_ary
+ nil
+ end
+
def method_missing(method, *args, &blk)
- if Gem::Specification.new.respond_to?(method)
- raise "LazySpecification has not been materialized yet (calling :#{method} #{args.inspect})" unless @specification
- @specification.send(method, *args, &blk)
- else
- super
- end
+ raise "LazySpecification has not been materialized yet (calling :#{method} #{args.inspect})" unless @specification
+
+ return super unless respond_to?(method)
+
+ @specification.send(method, *args, &blk)
end
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/lockfile_parser.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/lockfile_parser.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/lockfile_parser.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/lockfile_parser.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle
similarity index 90%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle
index 1b2b35d9..4ac481c7 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle
@@ -1,7 +1,7 @@
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
-.TH "BUNDLE" "1" "May 2011" "" ""
+.TH "BUNDLE" "1" "July 2011" "" ""
.
.SH "NAME"
\fBbundle\fR \- Ruby Dependency Management
@@ -65,6 +65,10 @@ Show all of the gems in the current bundle
Show the source location of a particular gem in the bundle
.
.TP
+\fBbundle outdated(1)\fR
+Show all of the outdated gems in the current bundle
+.
+.TP
\fBbundle console(1)\fR
Start an IRB session in the context of the current bundle
.
@@ -74,7 +78,11 @@ Open an installed gem in the editor
.
.TP
\fBbundle viz(1)\fR
-Generate a visual representation of your dependencies
+Generate a visual representation of your dependencies <<<<<<< HEAD
+.
+.TP
+\fBbundle benchmark(1)\fR:
+
.
.TP
\fBbundle init(1)\fR
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-config b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-config
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-config
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-config
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-config.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-config.txt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-config.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-config.txt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-exec b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-exec
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-exec
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-exec
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-exec.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-exec.txt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-exec.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-exec.txt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-install b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-install
similarity index 97%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-install
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-install
index 50dea0ef..abe6429f 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-install
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-install
@@ -1,7 +1,7 @@
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
-.TH "BUNDLE\-INSTALL" "1" "May 2011" "" ""
+.TH "BUNDLE\-INSTALL" "1" "July 2011" "" ""
.
.SH "NAME"
\fBbundle\-install\fR \- Install the dependencies specified in your Gemfile
@@ -17,6 +17,7 @@
[\-\-without=GROUP1[ GROUP2\.\.\.]]
[\-\-local] [\-\-deployment]
[\-\-binstubs[=DIRECTORY]]
+ [\-\-standalone[=GROUP1[ GROUP2\.\.\.]]]
[\-\-quiet]
.
.fi
@@ -62,6 +63,10 @@ Switches bundler\'s defaults into \fIdeployment mode\fR\. Do not use this flag o
\fB\-\-binstubs[=
]\fR
Create a directory (defaults to \fBbin\fR) containing an executable that runs in the context of the bundle\. For instance, if the \fBrails\fR gem comes with a \fBrails\fR executable, this flag will create a \fBbin/rails\fR executable that ensures that all dependencies used come from the bundled gems\.
.
+.TP
+\fB\-\-standalone[=]\fR
+Make a bundle that can work without Ruby Gems or Bundler at runtime\. It takes a space separated list of groups to install\. It creates a \fBbundle\fR directory and installs the bundle there\. It also generates a \fBbundle/bundler/setup\.rb\fR file to replace Bundler\'s own setup\.
+.
.SH "DEPLOYMENT MODE"
Bundler\'s defaults are optimized for development\. To switch to defaults optimized for deployment, use the \fB\-\-deployment\fR flag\. Do not activate deployment mode on development machines, as it will cause in an error when the Gemfile is modified\.
.
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-install.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-install.txt
similarity index 97%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-install.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-install.txt
index 276af004..1e167c85 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-install.txt
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-install.txt
@@ -14,6 +14,7 @@ SYNOPSIS
[--without=GROUP1[ GROUP2...]]
[--local] [--deployment]
[--binstubs[=DIRECTORY]]
+ [--standalone[=GROUP1[ GROUP2...]]]
[--quiet]
@@ -74,6 +75,13 @@ OPTIONS
bin/rails executable that ensures that all dependencies used
come from the bundled gems.
+ --standalone[=]
+ Make a bundle that can work without Ruby Gems or Bundler at run-
+ time. It takes a space separated list of groups to install. It
+ creates a bundle directory and installs the bundle there. It
+ also generates a bundle/bundler/setup.rb file to replace
+ Bundler's own setup.
+
DEPLOYMENT MODE
Bundler's defaults are optimized for development. To switch to defaults
optimized for deployment, use the --deployment flag. Do not activate
@@ -335,4 +343,4 @@ CONSERVATIVE UPDATING
- May 2011 BUNDLE-INSTALL(1)
+ July 2011 BUNDLE-INSTALL(1)
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-package b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-package
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-package
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-package
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-package.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-package.txt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-package.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-package.txt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-update b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-update
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-update
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-update
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-update.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-update.txt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle-update.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle-update.txt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle.txt
similarity index 89%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle.txt
index 35d7d08c..d2e99b88 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/bundle.txt
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/bundle.txt
@@ -54,6 +54,9 @@ UTILITIES
bundle show(1)
Show the source location of a particular gem in the bundle
+ bundle outdated(1)
+ Show all of the outdated gems in the current bundle
+
bundle console(1)
Start an IRB session in the context of the current bundle
@@ -61,7 +64,11 @@ UTILITIES
Open an installed gem in the editor
bundle viz(1)
- Generate a visual representation of your dependencies
+ Generate a visual representation of your dependencies <<<<<<<
+ HEAD
+
+ bundle benchmark(1):
+
bundle init(1)
Generate a simple Gemfile, placed in the current directory
@@ -83,4 +90,4 @@ OBSOLETE
- May 2011 BUNDLE(1)
+ July 2011 BUNDLE(1)
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/gemfile.5 b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/gemfile.5
similarity index 99%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/gemfile.5
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/gemfile.5
index db3c5871..ab17a676 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/gemfile.5
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/gemfile.5
@@ -1,7 +1,7 @@
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
-.TH "GEMFILE" "5" "May 2011" "" ""
+.TH "GEMFILE" "5" "July 2011" "" ""
.
.SH "NAME"
\fBGemfile\fR \- A format for describing gem dependencies for Ruby programs
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/gemfile.5.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/gemfile.5.txt
similarity index 99%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/gemfile.5.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/gemfile.5.txt
index 1745de6a..bcee78cb 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/man/gemfile.5.txt
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/man/gemfile.5.txt
@@ -342,4 +342,4 @@ SOURCE PRIORITY
- May 2011 GEMFILE(5)
+ July 2011 GEMFILE(5)
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/remote_specification.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/remote_specification.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/remote_specification.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/remote_specification.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/resolver.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/resolver.rb
similarity index 96%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/resolver.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/resolver.rb
index 4948357c..45519a73 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/resolver.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/resolver.rb
@@ -145,7 +145,7 @@ module Bundler
def debug
if ENV['DEBUG_RESOLVER']
debug_info = yield
- debug_info = debug_info.inpsect unless debug_info.is_a?(String)
+ debug_info = debug_info.inspect unless debug_info.is_a?(String)
$stderr.puts debug_info
end
end
@@ -279,14 +279,6 @@ module Bundler
end
raise GemNotFound, message
else
- if @missing_gems[current] >= 5
- message = "Bundler could not find find gem #{current.required_by.last},"
- message << "which is required by gem #{current}."
- raise GemNotFound, message
- end
- @missing_gems[current] += 1
-
- debug { " Could not find #{current} by #{current.required_by.last}" }
@errors[current.name] = [nil, current]
end
end
@@ -356,7 +348,8 @@ module Bundler
def search(dep)
if base = @base[dep.name] and base.any?
- d = Gem::Dependency.new(base.first.name, *[dep.requirement.as_list, base.first.version].flatten)
+ reqs = [dep.requirement.as_list, base.first.version.to_s].flatten.compact
+ d = Gem::Dependency.new(base.first.name, *reqs)
else
d = dep.dep
end
@@ -456,7 +449,8 @@ module Bundler
# the rest of the time, the gem cannot be found because it does not exist in the known sources
else
if requirement.required_by.first
- o << "Could not find gem '#{clean_req(requirement)}', required by '#{clean_req(requirement.required_by.first)}', in any of the sources\n"
+ o << "Could not find gem '#{clean_req(requirement)}', which is required by "
+ o << "gem '#{clean_req(requirement.required_by.first)}', in any of the sources."
else
o << "Could not find gem '#{clean_req(requirement)} in any of the sources\n"
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/rubygems_ext.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/rubygems_ext.rb
similarity index 99%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/rubygems_ext.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/rubygems_ext.rb
index 95a382f0..54e72c53 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/rubygems_ext.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/rubygems_ext.rb
@@ -157,6 +157,7 @@ module Gem
alias eql? ==
end
+
end
module Bundler
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/rubygems_integration.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/rubygems_integration.rb
similarity index 91%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/rubygems_integration.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/rubygems_integration.rb
index f2d2f5e2..1c0c5505 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/rubygems_integration.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/rubygems_integration.rb
@@ -123,7 +123,7 @@ module Bundler
if executables.include? File.basename(caller.first.split(':').first)
return
end
- opts = reqs.last.is_a?(Hash) ? reqs.pop : {}
+ reqs.pop if reqs.last.is_a?(Hash)
unless dep.respond_to?(:name) && dep.respond_to?(:requirement)
dep = Gem::Dependency.new(dep, reqs)
@@ -250,7 +250,17 @@ module Bundler
Gem.clear_paths
end
- # Rubygems versions 1.3.6 through 1.6.2
+ # This backports the correct segment generation code from Rubygems 1.4+
+ # by monkeypatching it into the method in Rubygems 1.3.6 and 1.3.7.
+ def backport_segment_generation
+ Gem::Version.send(:define_method, :segments) do
+ @segments ||= @version.scan(/[0-9]+|[a-z]+/i).map do |s|
+ /^\d+$/ =~ s ? s.to_i : s
+ end
+ end
+ end
+
+ # Rubygems 1.4 through 1.6
class Legacy < RubygemsIntegration
def stub_rubygems(specs)
stub_source_index137(specs)
@@ -265,6 +275,14 @@ module Bundler
end
end
+ # Rubygems versions 1.3.6 and 1.3.7
+ class Ancient < Legacy
+ def initialize
+ super
+ backport_segment_generation
+ end
+ end
+
# Rubygems 1.7
class Transitional < Legacy
def stub_rubygems(specs)
@@ -313,8 +331,10 @@ module Bundler
@rubygems = RubygemsIntegration::AlmostModern.new
elsif Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.7.0')
@rubygems = RubygemsIntegration::Transitional.new
- else # Rubygems 1.3.6 through 1.6.2
+ elsif Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.4.0')
@rubygems = RubygemsIntegration::Legacy.new
+ else # Rubygems 1.3.6 and 1.3.7
+ @rubygems = RubygemsIntegration::Ancient.new
end
class << self
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/runtime.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/runtime.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/runtime.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/runtime.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/settings.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/settings.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/settings.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/settings.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/setup.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/setup.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/setup.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/setup.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/shared_helpers.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/shared_helpers.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/shared_helpers.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/shared_helpers.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/source.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/source.rb
similarity index 96%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/source.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/source.rb
index f18ace20..eaa7bb65 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/source.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/source.rb
@@ -158,11 +158,17 @@ module Bundler
end
def fetch_specs
- Index.build do |idx|
- idx.use installed_specs
- idx.use cached_specs if @allow_cached || @allow_remote
- idx.use remote_specs if @allow_remote
+ # remote_specs usually generates a way larger Index than the other
+ # sources, and large_idx.use small_idx is way faster than
+ # small_idx.use large_idx.
+ if @allow_remote
+ idx = remote_specs.dup
+ else
+ idx = Index.new
end
+ idx.use(cached_specs, :override_dupes) if @allow_cached || @allow_remote
+ idx.use(installed_specs, :override_dupes)
+ idx
end
def installed_specs
@@ -280,7 +286,7 @@ module Bundler
attr_writer :name
attr_accessor :version
- DEFAULT_GLOB = "{,*/}*.gemspec"
+ DEFAULT_GLOB = "{,*,*/*}.gemspec"
def initialize(options)
@options = options
@@ -362,9 +368,9 @@ module Bundler
s.relative_loaded_from = "#{@name}.gemspec"
s.authors = ["no one"]
if expanded_path.join("bin").exist?
- binaries = expanded_path.join("bin").children
- binaries.reject!{|p| File.directory?(p) }
- s.executables = binaries.map{|c| c.basename.to_s }
+ executables = expanded_path.join("bin").children
+ executables.reject!{|p| File.directory?(p) }
+ s.executables = executables.map{|c| c.basename.to_s }
end
end
end
@@ -585,7 +591,7 @@ module Bundler
end
def base_name
- File.basename(uri.sub(%r{^(\w+://)?([^/:]+:)},''), ".git")
+ File.basename(uri.sub(%r{^(\w+://)?([^/:]+:)?(//\w*/)?(\w*/)*},''),".git")
end
def shortref_for_display(ref)
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/spec_set.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/spec_set.rb
similarity index 94%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/spec_set.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/spec_set.rb
index 901888a1..3149c752 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/spec_set.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/spec_set.rb
@@ -1,21 +1,18 @@
require 'tsort'
+require 'forwardable'
module Bundler
class SpecSet
+ extend Forwardable
include TSort, Enumerable
+ def_delegators :@specs, :<<, :length, :add, :remove
+ def_delegators :sorted, :each
+
def initialize(specs)
@specs = specs.sort_by { |s| s.name }
end
- def each
- sorted.each { |s| yield s }
- end
-
- def length
- @specs.length
- end
-
def for(dependencies, skip = [], check = false, match_current_platform = false)
handled, deps, specs = {}, dependencies.dup, []
skip << 'bundler'
@@ -68,6 +65,10 @@ module Bundler
value
end
+ def sort!
+ self
+ end
+
def to_a
sorted.dup
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/Executable b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/Executable
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/Executable
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/Executable
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/Gemfile b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/Gemfile
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/Gemfile
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/Gemfile
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/Gemfile.tt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/Gemfile.tt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/Gemfile.tt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/Gemfile.tt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/Rakefile.tt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/Rakefile.tt
new file mode 100644
index 00000000..29955274
--- /dev/null
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/Rakefile.tt
@@ -0,0 +1 @@
+require "bundler/gem_tasks"
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/bin/newgem.tt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/bin/newgem.tt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/bin/newgem.tt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/bin/newgem.tt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/gitignore.tt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/gitignore.tt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/gitignore.tt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/gitignore.tt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/lib/newgem.rb.tt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/lib/newgem.rb.tt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/lib/newgem.rb.tt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/lib/newgem.rb.tt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/lib/newgem/version.rb.tt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/lib/newgem/version.rb.tt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/lib/newgem/version.rb.tt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/lib/newgem/version.rb.tt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/newgem.gemspec.tt b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/newgem.gemspec.tt
similarity index 84%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/newgem.gemspec.tt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/newgem.gemspec.tt
index 3b7ace15..35b3e3af 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/templates/newgem/newgem.gemspec.tt
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/templates/newgem/newgem.gemspec.tt
@@ -17,4 +17,8 @@ Gem::Specification.new do |s|
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"]
+
+ # specify any dependencies here; for example:
+ # s.add_development_dependency "rspec"
+ # s.add_runtime_dependency "rest-client"
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/ui.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/ui.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/ui.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/ui.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor.rb
old mode 100755
new mode 100644
similarity index 85%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor.rb
index d9399f78..92b24342
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor.rb
@@ -18,6 +18,23 @@ class Thor
end
end
+ # Registers another Thor subclass as a command.
+ #
+ # ==== Parameters
+ # klass:: Thor subclass to register
+ # command:: Subcommand name to use
+ # usage:: Short usage for the subcommand
+ # description:: Description for the subcommand
+ def register(klass, subcommand_name, usage, description, options={})
+ if klass <= Thor::Group
+ desc usage, description, options
+ define_method(subcommand_name) { invoke klass }
+ else
+ desc usage, description, options
+ subcommand subcommand_name, klass
+ end
+ end
+
# Defines the usage and the description of the next task.
#
# ==== Parameters
@@ -252,8 +269,7 @@ class Thor
# the namespace should be displayed as arguments.
#
def banner(task, namespace = nil, subcommand = false)
- base = File.basename($0).split(" ").first
- "#{base} #{task.formatted_usage(self, $thor_runner, subcommand)}"
+ "#{basename} #{task.formatted_usage(self, $thor_runner, subcommand)}"
end
def baseclass #:nodoc:
@@ -295,17 +311,40 @@ class Thor
# Receives a task name (can be nil), and try to get a map from it.
# If a map can't be found use the sent name or the default task.
def normalize_task_name(meth) #:nodoc:
- meth = map[meth.to_s] || meth || default_task
+ meth = map[meth.to_s] || find_subcommand_and_update_argv(meth) || meth || default_task
meth.to_s.gsub('-','_') # treat foo-bar > foo_bar
end
+ # terrible hack that overwrites ARGV
+ def find_subcommand_and_update_argv(subcmd_name) #:nodoc:
+ return unless subcmd_name
+ cmd = find_subcommand(subcmd_name)
+ ARGV[0] = cmd if cmd
+ cmd
+ end
+
+ def find_subcommand(subcmd_name)
+ possibilities = find_subcommand_possibilities subcmd_name
+ if possibilities.size > 1
+ raise "Ambiguous subcommand #{subcmd_name} matches [#{possibilities.join(', ')}]"
+ elsif possibilities.size < 1
+ return nil
+ end
+
+ possibilities.first
+ end
+
+ def find_subcommand_possibilities(subcmd_name)
+ len = subcmd_name.length
+ all_tasks.map {|t| t.first}.select { |n| subcmd_name == n[0, len] }
+ end
+
def subcommand_help(cmd)
desc "help [COMMAND]", "Describe subcommands or one specific subcommand"
class_eval <<-RUBY
def help(task = nil, subcommand = true); super; end
RUBY
end
-
end
include Thor::Base
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions.rb
old mode 100755
new mode 100644
similarity index 89%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions.rb
index bfccbf8f..3712c5f4
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions.rb
@@ -1,10 +1,12 @@
require 'fileutils'
require 'uri'
require 'thor/core_ext/file_binary_read'
-
-Dir[File.join(File.dirname(__FILE__), "actions", "*.rb")].each do |action|
- require action
-end
+require 'thor/actions/create_file'
+require 'thor/actions/create_link'
+require 'thor/actions/directory'
+require 'thor/actions/empty_directory'
+require 'thor/actions/file_manipulation'
+require 'thor/actions/inject_into_file'
class Thor
module Actions
@@ -158,13 +160,23 @@ class Thor
#
def inside(dir='', config={}, &block)
verbose = config.fetch(:verbose, false)
+ pretend = options[:pretend]
say_status :inside, dir, verbose
shell.padding += 1 if verbose
@destination_stack.push File.expand_path(dir, destination_root)
- FileUtils.mkdir_p(destination_root) unless File.exist?(destination_root)
- FileUtils.cd(destination_root) { block.arity == 1 ? yield(destination_root) : yield }
+ # If the directory doesnt exist and we're not pretending
+ if !File.exist?(destination_root) && !pretend
+ FileUtils.mkdir_p(destination_root)
+ end
+
+ if pretend
+ # In pretend mode, just yield down to the block
+ block.arity == 1 ? yield(destination_root) : yield
+ else
+ FileUtils.cd(destination_root) { block.arity == 1 ? yield(destination_root) : yield }
+ end
@destination_stack.pop
shell.padding -= 1 if verbose
@@ -210,7 +222,7 @@ class Thor
#
# ==== Parameters
# command:: the command to be executed.
- # config:: give :verbose => false to not log the status. Specify :with
+ # config:: give :verbose => false to not log the status, :capture => true to hide to output. Specify :with
# to append an executable to command executation.
#
# ==== Example
@@ -231,7 +243,10 @@ class Thor
end
say_status :run, desc, config.fetch(:verbose, true)
- `#{command}` unless options[:pretend]
+
+ unless options[:pretend]
+ config[:capture] ? `#{command}` : system("#{command}")
+ end
end
# Executes a ruby script (taking into account WIN32 platform quirks).
@@ -251,8 +266,9 @@ class Thor
# ==== Parameters
# task:: the task to be invoked
# args:: arguments to the task
- # config:: give :verbose => false to not log the status. Other options
- # are given as parameter to Thor.
+ # config:: give :verbose => false to not log the status, :capture => true to hide to output.
+ # Other options are given as parameter to Thor.
+ #
#
# ==== Examples
#
@@ -266,12 +282,13 @@ class Thor
config = args.last.is_a?(Hash) ? args.pop : {}
verbose = config.key?(:verbose) ? config.delete(:verbose) : true
pretend = config.key?(:pretend) ? config.delete(:pretend) : false
+ capture = config.key?(:capture) ? config.delete(:capture) : false
args.unshift task
args.push Thor::Options.to_switches(config)
command = args.join(' ').strip
- run command, :with => :thor, :verbose => verbose, :pretend => pretend
+ run command, :with => :thor, :verbose => verbose, :pretend => pretend, :capture => capture
end
protected
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/create_file.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/create_file.rb
old mode 100755
new mode 100644
similarity index 95%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/create_file.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/create_file.rb
index 5541ad5f..ed5973a4
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/create_file.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/create_file.rb
@@ -18,7 +18,7 @@ class Thor
# "vhost.name = #{hostname}"
# end
#
- # create_file "config/apach.conf", "your apache config"
+ # create_file "config/apache.conf", "your apache config"
#
def create_file(destination, *args, &block)
config = args.last.is_a?(Hash) ? args.pop : {}
@@ -27,7 +27,7 @@ class Thor
end
alias :add_file :create_file
- # AddFile is a subset of Template, which instead of rendering a file with
+ # CreateFile is a subset of Template, which instead of rendering a file with
# ERB, it gets the content from the user.
#
class CreateFile < EmptyDirectory #:nodoc:
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/create_link.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/create_link.rb
new file mode 100644
index 00000000..1975644a
--- /dev/null
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/create_link.rb
@@ -0,0 +1,57 @@
+require 'thor/actions/create_file'
+
+class Thor
+ module Actions
+
+ # Create a new file relative to the destination root from the given source.
+ #
+ # ==== Parameters
+ # destination:: the relative path to the destination root.
+ # source:: the relative path to the source root.
+ # config:: give :verbose => false to not log the status.
+ # :: give :symbolic => false for hard link.
+ #
+ # ==== Examples
+ #
+ # create_link "config/apache.conf", "/etc/apache.conf"
+ #
+ def create_link(destination, *args, &block)
+ config = args.last.is_a?(Hash) ? args.pop : {}
+ source = args.first
+ action CreateLink.new(self, destination, source, config)
+ end
+ alias :add_link :create_link
+
+ # CreateLink is a subset of CreateFile, which instead of taking a block of
+ # data, just takes a source string from the user.
+ #
+ class CreateLink < CreateFile #:nodoc:
+ attr_reader :data
+
+ # Checks if the content of the file at the destination is identical to the rendered result.
+ #
+ # ==== Returns
+ # Boolean:: true if it is identical, false otherwise.
+ #
+ def identical?
+ exists? && File.identical?(render, destination)
+ end
+
+ def invoke!
+ invoke_with_conflict_check do
+ FileUtils.mkdir_p(File.dirname(destination))
+ # Create a symlink by default
+ config[:symbolic] ||= true
+ File.unlink(destination) if exists?
+ if config[:symbolic]
+ File.symlink(render, destination)
+ else
+ File.link(render, destination)
+ end
+ end
+ given_destination
+ end
+
+ end
+ end
+end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/directory.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/directory.rb
old mode 100755
new mode 100644
similarity index 95%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/directory.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/directory.rb
index 717508eb..dc238939
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/directory.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/directory.rb
@@ -21,7 +21,7 @@ class Thor
# directory "doc"
#
# It will create a doc directory in the destination with the following
- # files (assuming that the app_name is "blog"):
+ # files (assuming that the `app_name` method returns the value "blog"):
#
# doc/
# components/
@@ -70,7 +70,7 @@ class Thor
lookup = config[:recursive] ? File.join(source, '**') : source
lookup = File.join(lookup, '{*,.[a-z]*}')
- Dir[lookup].each do |file_source|
+ Dir[lookup].sort.each do |file_source|
next if File.directory?(file_source)
file_destination = File.join(given_destination, file_source.gsub(source, '.'))
file_destination.gsub!('/./', '/')
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/empty_directory.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/empty_directory.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/empty_directory.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/empty_directory.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/file_manipulation.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/file_manipulation.rb
old mode 100755
new mode 100644
similarity index 77%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/file_manipulation.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/file_manipulation.rb
index e9494626..ad049b3c
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/file_manipulation.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/file_manipulation.rb
@@ -30,6 +30,28 @@ class Thor
end
end
+ # Links the file from the relative source to the relative destination. If
+ # the destination is not given it's assumed to be equal to the source.
+ #
+ # ==== Parameters
+ # source:: the relative path to the source root.
+ # destination:: the relative path to the destination root.
+ # config:: give :verbose => false to not log the status.
+ #
+ # ==== Examples
+ #
+ # link_file "README", "doc/README"
+ #
+ # link_file "doc/README"
+ #
+ def link_file(source, *args, &block)
+ config = args.last.is_a?(Hash) ? args.pop : {}
+ destination = args.first || source
+ source = File.expand_path(find_in_source_paths(source.to_s))
+
+ create_link destination, source, config
+ end
+
# Gets the content at the given address and places it at the given relative
# destination. If a block is given instead of destination, the content of
# the url is yielded and used as location.
@@ -51,7 +73,7 @@ class Thor
config = args.last.is_a?(Hash) ? args.pop : {}
destination = args.first
- source = File.expand_path(find_in_source_paths(source.to_s)) unless source =~ /^http\:\/\//
+ source = File.expand_path(find_in_source_paths(source.to_s)) unless source =~ /^https?\:\/\//
render = open(source) {|input| input.binmode.read }
destination ||= if block_given?
@@ -80,13 +102,13 @@ class Thor
#
def template(source, *args, &block)
config = args.last.is_a?(Hash) ? args.pop : {}
- destination = args.first || source
+ destination = args.first || source.sub(/\.tt$/, '')
source = File.expand_path(find_in_source_paths(source.to_s))
context = instance_eval('binding')
create_file destination, nil, config do
- content = ERB.new(::File.binread(source), nil, '-').result(context)
+ content = ERB.new(::File.binread(source), nil, '-', '@output_buffer').result(context)
content = block.call(content) if block
content
end
@@ -110,7 +132,7 @@ class Thor
FileUtils.chmod_R(mode, path) unless options[:pretend]
end
- # Prepend text to a file. Since it depends on inject_into_file, it's reversible.
+ # Prepend text to a file. Since it depends on insert_into_file, it's reversible.
#
# ==== Parameters
# path:: path of the file to be changed
@@ -119,19 +141,20 @@ class Thor
#
# ==== Example
#
- # prepend_file 'config/environments/test.rb', 'config.gem "rspec"'
+ # prepend_to_file 'config/environments/test.rb', 'config.gem "rspec"'
#
- # prepend_file 'config/environments/test.rb' do
+ # prepend_to_file 'config/environments/test.rb' do
# 'config.gem "rspec"'
# end
#
- def prepend_file(path, *args, &block)
+ def prepend_to_file(path, *args, &block)
config = args.last.is_a?(Hash) ? args.pop : {}
config.merge!(:after => /\A/)
- inject_into_file(path, *(args << config), &block)
+ insert_into_file(path, *(args << config), &block)
end
+ alias_method :prepend_file, :prepend_to_file
- # Append text to a file. Since it depends on inject_into_file, it's reversible.
+ # Append text to a file. Since it depends on insert_into_file, it's reversible.
#
# ==== Parameters
# path:: path of the file to be changed
@@ -140,20 +163,21 @@ class Thor
#
# ==== Example
#
- # append_file 'config/environments/test.rb', 'config.gem "rspec"'
+ # append_to_file 'config/environments/test.rb', 'config.gem "rspec"'
#
- # append_file 'config/environments/test.rb' do
+ # append_to_file 'config/environments/test.rb' do
# 'config.gem "rspec"'
# end
#
- def append_file(path, *args, &block)
+ def append_to_file(path, *args, &block)
config = args.last.is_a?(Hash) ? args.pop : {}
config.merge!(:before => /\z/)
- inject_into_file(path, *(args << config), &block)
+ insert_into_file(path, *(args << config), &block)
end
+ alias_method :append_file, :append_to_file
# Injects text right after the class definition. Since it depends on
- # inject_into_file, it's reversible.
+ # insert_into_file, it's reversible.
#
# ==== Parameters
# path:: path of the file to be changed
@@ -172,7 +196,7 @@ class Thor
def inject_into_class(path, klass, *args, &block)
config = args.last.is_a?(Hash) ? args.pop : {}
config.merge!(:after => /class #{klass}\n|class #{klass} .*\n/)
- inject_into_file(path, *(args << config), &block)
+ insert_into_file(path, *(args << config), &block)
end
# Run a regular expression replacement on a file.
@@ -225,5 +249,22 @@ class Thor
end
alias :remove_dir :remove_file
+ private
+ attr_accessor :output_buffer
+ def concat(string)
+ @output_buffer.concat(string)
+ end
+
+ def capture(*args, &block)
+ with_output_buffer { block.call(*args) }
+ end
+
+ def with_output_buffer(buf = '') #:nodoc:
+ self.output_buffer, old_buffer = buf, output_buffer
+ yield
+ output_buffer
+ ensure
+ self.output_buffer = old_buffer
+ end
end
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/inject_into_file.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/inject_into_file.rb
old mode 100755
new mode 100644
similarity index 84%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/inject_into_file.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/inject_into_file.rb
index 812c2e7d..c48cfab5
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/actions/inject_into_file.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/actions/inject_into_file.rb
@@ -10,19 +10,19 @@ class Thor
# destination:: Relative path to the destination root
# data:: Data to add to the file. Can be given as a block.
# config:: give :verbose => false to not log the status and the flag
- # for injection (:after or :before) or :force => true for
+ # for injection (:after or :before) or :force => true for
# insert two or more times the same content.
- #
+ #
# ==== Examples
#
- # inject_into_file "config/environment.rb", "config.gem :thor", :after => "Rails::Initializer.run do |config|\n"
+ # insert_into_file "config/environment.rb", "config.gem :thor", :after => "Rails::Initializer.run do |config|\n"
#
- # inject_into_file "config/environment.rb", :after => "Rails::Initializer.run do |config|\n" do
+ # insert_into_file "config/environment.rb", :after => "Rails::Initializer.run do |config|\n" do
# gems = ask "Which gems would you like to add?"
# gems.split(" ").map{ |gem| " config.gem :#{gem}" }.join("\n")
# end
#
- def inject_into_file(destination, *args, &block)
+ def insert_into_file(destination, *args, &block)
if block_given?
data, config = block, args.shift
else
@@ -30,6 +30,7 @@ class Thor
end
action InjectIntoFile.new(self, destination, data, config)
end
+ alias_method :inject_into_file, :insert_into_file
class InjectIntoFile < EmptyDirectory #:nodoc:
attr_reader :replacement, :flag, :behavior
@@ -76,12 +77,16 @@ class Thor
protected
def say_status(behavior)
- status = if flag == /\A/
- behavior == :invoke ? :prepend : :unprepend
- elsif flag == /\z/
- behavior == :invoke ? :append : :unappend
+ status = if behavior == :invoke
+ if flag == /\A/
+ :prepend
+ elsif flag == /\z/
+ :append
+ else
+ :insert
+ end
else
- behavior == :invoke ? :inject : :deinject
+ :subtract
end
super(status, config[:verbose])
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/base.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/base.rb
old mode 100755
new mode 100644
similarity index 96%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/base.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/base.rb
index 6412ace6..65399ffb
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/base.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/base.rb
@@ -94,8 +94,6 @@ class Thor
end
module ClassMethods
- attr_accessor :debugging
-
def attr_reader(*) #:nodoc:
no_tasks { super }
end
@@ -384,14 +382,29 @@ class Thor
# script.invoke(:task, first_arg, second_arg, third_arg)
#
def start(given_args=ARGV, config={})
- self.debugging = given_args.delete("--debug")
config[:shell] ||= Thor::Base.shell.new
dispatch(nil, given_args.dup, nil, config)
rescue Thor::Error => e
- debugging ? (raise e) : config[:shell].error(e.message)
+ ENV["THOR_DEBUG"] == "1" ? (raise e) : config[:shell].error(e.message)
exit(1) if exit_on_failure?
end
+ # Allows to use private methods from parent in child classes as tasks.
+ #
+ # ==== Paremeters
+ # names:: Method names to be used as tasks
+ #
+ # ==== Examples
+ #
+ # public_task :foo
+ # public_task :foo, :bar, :baz
+ #
+ def public_task(*names)
+ names.each do |name|
+ class_eval "def #{name}(*); super end"
+ end
+ end
+
def handle_no_task_error(task) #:nodoc:
if $thor_runner
raise UndefinedTaskError, "Could not find task #{task.inspect} in #{namespace.inspect} namespace."
@@ -531,6 +544,13 @@ class Thor
false
end
+ #
+ # The basename of the program invoking the thor class.
+ #
+ def basename
+ File.basename($0).split(' ').first
+ end
+
# SIGNATURE: Sets the baseclass. This is where the superclass lookup
# finishes.
def baseclass #:nodoc:
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/core_ext/file_binary_read.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/core_ext/file_binary_read.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/core_ext/file_binary_read.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/core_ext/file_binary_read.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/core_ext/hash_with_indifferent_access.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/core_ext/hash_with_indifferent_access.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/core_ext/hash_with_indifferent_access.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/core_ext/hash_with_indifferent_access.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/core_ext/ordered_hash.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/core_ext/ordered_hash.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/core_ext/ordered_hash.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/core_ext/ordered_hash.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/error.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/error.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/error.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/error.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/group.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/group.rb
new file mode 100644
index 00000000..3dbab98a
--- /dev/null
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/group.rb
@@ -0,0 +1,273 @@
+require 'thor/base'
+
+# Thor has a special class called Thor::Group. The main difference to Thor class
+# is that it invokes all tasks at once. It also include some methods that allows
+# invocations to be done at the class method, which are not available to Thor
+# tasks.
+class Thor::Group
+ class << self
+ # The description for this Thor::Group. If none is provided, but a source root
+ # exists, tries to find the USAGE one folder above it, otherwise searches
+ # in the superclass.
+ #
+ # ==== Parameters
+ # description:: The description for this Thor::Group.
+ #
+ def desc(description=nil)
+ case description
+ when nil
+ @desc ||= from_superclass(:desc, nil)
+ else
+ @desc = description
+ end
+ end
+
+ # Prints help information.
+ #
+ # ==== Options
+ # short:: When true, shows only usage.
+ #
+ def help(shell)
+ shell.say "Usage:"
+ shell.say " #{banner}\n"
+ shell.say
+ class_options_help(shell)
+ shell.say self.desc if self.desc
+ end
+
+ # Stores invocations for this class merging with superclass values.
+ #
+ def invocations #:nodoc:
+ @invocations ||= from_superclass(:invocations, {})
+ end
+
+ # Stores invocation blocks used on invoke_from_option.
+ #
+ def invocation_blocks #:nodoc:
+ @invocation_blocks ||= from_superclass(:invocation_blocks, {})
+ end
+
+ # Invoke the given namespace or class given. It adds an instance
+ # method that will invoke the klass and task. You can give a block to
+ # configure how it will be invoked.
+ #
+ # The namespace/class given will have its options showed on the help
+ # usage. Check invoke_from_option for more information.
+ #
+ def invoke(*names, &block)
+ options = names.last.is_a?(Hash) ? names.pop : {}
+ verbose = options.fetch(:verbose, true)
+
+ names.each do |name|
+ invocations[name] = false
+ invocation_blocks[name] = block if block_given?
+
+ class_eval <<-METHOD, __FILE__, __LINE__
+ def _invoke_#{name.to_s.gsub(/\W/, '_')}
+ klass, task = self.class.prepare_for_invocation(nil, #{name.inspect})
+
+ if klass
+ say_status :invoke, #{name.inspect}, #{verbose.inspect}
+ block = self.class.invocation_blocks[#{name.inspect}]
+ _invoke_for_class_method klass, task, &block
+ else
+ say_status :error, %(#{name.inspect} [not found]), :red
+ end
+ end
+ METHOD
+ end
+ end
+
+ # Invoke a thor class based on the value supplied by the user to the
+ # given option named "name". A class option must be created before this
+ # method is invoked for each name given.
+ #
+ # ==== Examples
+ #
+ # class GemGenerator < Thor::Group
+ # class_option :test_framework, :type => :string
+ # invoke_from_option :test_framework
+ # end
+ #
+ # ==== Boolean options
+ #
+ # In some cases, you want to invoke a thor class if some option is true or
+ # false. This is automatically handled by invoke_from_option. Then the
+ # option name is used to invoke the generator.
+ #
+ # ==== Preparing for invocation
+ #
+ # In some cases you want to customize how a specified hook is going to be
+ # invoked. You can do that by overwriting the class method
+ # prepare_for_invocation. The class method must necessarily return a klass
+ # and an optional task.
+ #
+ # ==== Custom invocations
+ #
+ # You can also supply a block to customize how the option is giong to be
+ # invoked. The block receives two parameters, an instance of the current
+ # class and the klass to be invoked.
+ #
+ def invoke_from_option(*names, &block)
+ options = names.last.is_a?(Hash) ? names.pop : {}
+ verbose = options.fetch(:verbose, :white)
+
+ names.each do |name|
+ unless class_options.key?(name)
+ raise ArgumentError, "You have to define the option #{name.inspect} " <<
+ "before setting invoke_from_option."
+ end
+
+ invocations[name] = true
+ invocation_blocks[name] = block if block_given?
+
+ class_eval <<-METHOD, __FILE__, __LINE__
+ def _invoke_from_option_#{name.to_s.gsub(/\W/, '_')}
+ return unless options[#{name.inspect}]
+
+ value = options[#{name.inspect}]
+ value = #{name.inspect} if TrueClass === value
+ klass, task = self.class.prepare_for_invocation(#{name.inspect}, value)
+
+ if klass
+ say_status :invoke, value, #{verbose.inspect}
+ block = self.class.invocation_blocks[#{name.inspect}]
+ _invoke_for_class_method klass, task, &block
+ else
+ say_status :error, %(\#{value} [not found]), :red
+ end
+ end
+ METHOD
+ end
+ end
+
+ # Remove a previously added invocation.
+ #
+ # ==== Examples
+ #
+ # remove_invocation :test_framework
+ #
+ def remove_invocation(*names)
+ names.each do |name|
+ remove_task(name)
+ remove_class_option(name)
+ invocations.delete(name)
+ invocation_blocks.delete(name)
+ end
+ end
+
+ # Overwrite class options help to allow invoked generators options to be
+ # shown recursively when invoking a generator.
+ #
+ def class_options_help(shell, groups={}) #:nodoc:
+ get_options_from_invocations(groups, class_options) do |klass|
+ klass.send(:get_options_from_invocations, groups, class_options)
+ end
+ super(shell, groups)
+ end
+
+ # Get invocations array and merge options from invocations. Those
+ # options are added to group_options hash. Options that already exists
+ # in base_options are not added twice.
+ #
+ def get_options_from_invocations(group_options, base_options) #:nodoc:
+ invocations.each do |name, from_option|
+ value = if from_option
+ option = class_options[name]
+ option.type == :boolean ? name : option.default
+ else
+ name
+ end
+ next unless value
+
+ klass, task = prepare_for_invocation(name, value)
+ next unless klass && klass.respond_to?(:class_options)
+
+ value = value.to_s
+ human_name = value.respond_to?(:classify) ? value.classify : value
+
+ group_options[human_name] ||= []
+ group_options[human_name] += klass.class_options.values.select do |option|
+ base_options[option.name.to_sym].nil? && option.group.nil? &&
+ !group_options.values.flatten.any? { |i| i.name == option.name }
+ end
+
+ yield klass if block_given?
+ end
+ end
+
+ # Returns tasks ready to be printed.
+ def printable_tasks(*)
+ item = []
+ item << banner
+ item << (desc ? "# #{desc.gsub(/\s+/m,' ')}" : "")
+ [item]
+ end
+
+ def handle_argument_error(task, error) #:nodoc:
+ raise error, "#{task.name.inspect} was called incorrectly. Are you sure it has arity equals to 0?"
+ end
+
+ protected
+
+ # The method responsible for dispatching given the args.
+ def dispatch(task, given_args, given_opts, config) #:nodoc:
+ if Thor::HELP_MAPPINGS.include?(given_args.first)
+ help(config[:shell])
+ return
+ end
+
+ args, opts = Thor::Options.split(given_args)
+ opts = given_opts || opts
+
+ if task
+ new(args, opts, config).invoke_task(all_tasks[task])
+ else
+ new(args, opts, config).invoke_all
+ end
+ end
+
+ # The banner for this class. You can customize it if you are invoking the
+ # thor class by another ways which is not the Thor::Runner.
+ def banner
+ "#{basename} #{self_task.formatted_usage(self, false)}"
+ end
+
+ # Represents the whole class as a task.
+ def self_task #:nodoc:
+ Thor::DynamicTask.new(self.namespace, class_options)
+ end
+
+ def baseclass #:nodoc:
+ Thor::Group
+ end
+
+ def create_task(meth) #:nodoc:
+ tasks[meth.to_s] = Thor::Task.new(meth, nil, nil, nil, nil)
+ true
+ end
+ end
+
+ include Thor::Base
+
+ protected
+
+ # Shortcut to invoke with padding and block handling. Use internally by
+ # invoke and invoke_from_option class methods.
+ def _invoke_for_class_method(klass, task=nil, *args, &block) #:nodoc:
+ with_padding do
+ if block
+ case block.arity
+ when 3
+ block.call(self, klass, task)
+ when 2
+ block.call(self, klass)
+ when 1
+ instance_exec(klass, &block)
+ end
+ else
+ invoke klass, task, *args
+ end
+ end
+ end
+end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/invocation.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/invocation.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/invocation.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/invocation.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/argument.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/argument.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/argument.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/argument.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/arguments.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/arguments.rb
old mode 100755
new mode 100644
similarity index 97%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/arguments.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/arguments.rb
index 07850836..888ef692
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/arguments.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/arguments.rb
@@ -28,7 +28,7 @@ class Thor
@switches = arguments
arguments.each do |argument|
- if argument.default
+ if argument.default != nil
@assigns[argument.human_name] = argument.default
elsif argument.required?
@non_assigned_required << argument
@@ -94,7 +94,7 @@ class Thor
hash = {}
while current_is_value? && peek.include?(?:)
- key, value = shift.split(':')
+ key, value = shift.split(':',2)
hash[key] = value
end
hash
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/option.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/option.rb
old mode 100755
new mode 100644
similarity index 99%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/option.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/option.rb
index 496756db..c8f20b13
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/option.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/option.rb
@@ -37,7 +37,7 @@ class Thor
# string (--foo=value) or booleans (just --foo).
#
# By default all options are optional, unless :required is given.
- #
+ #
def self.parse(key, value)
if key.is_a?(Array)
name, *aliases = key
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/options.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/options.rb
old mode 100755
new mode 100644
similarity index 88%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/options.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/options.rb
index 2315b136..9b1d042d
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/parser/options.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/parser/options.rb
@@ -53,7 +53,9 @@ class Thor
@pile = args.dup
while peek
- if current_is_switch?
+ match, is_switch = current_is_switch?
+
+ if is_switch
case shift
when SHORT_SQ_RE
unshift($1.split('').map { |f| "-#{f}" })
@@ -68,7 +70,7 @@ class Thor
switch = normalize_switch(switch)
option = switch_option(switch)
@assigns[option.human_name] = parse_peek(switch, option)
- elsif current_is_switch_formatted?
+ elsif match
@unknown << shift
else
shift
@@ -83,7 +85,9 @@ class Thor
end
def check_unknown!
- raise UnknownArgumentError, "Unknown switches '#{@unknown.join(', ')}'" unless @unknown.empty?
+ unless ARGV.include?("exec") || ARGV.include?("config")
+ raise UnknownArgumentError, "Unknown switches '#{@unknown.join(', ')}'" unless @unknown.empty?
+ end
end
protected
@@ -92,15 +96,17 @@ class Thor
#
def current_is_switch?
case peek
- when LONG_RE, SHORT_RE, EQ_RE, SHORT_NUM
- switch?($1)
- when SHORT_SQ_RE
- $1.split('').any? { |f| switch?("-#{f}") }
+ when LONG_RE, SHORT_RE, EQ_RE, SHORT_NUM
+ [true, switch?($1)]
+ when SHORT_SQ_RE
+ [true, $1.split('').any? { |f| switch?("-#{f}") }]
+ else
+ [false, false]
end
end
- def switch_formatted?(arg)
- case arg
+ def current_is_switch_formatted?
+ case peek
when LONG_RE, SHORT_RE, EQ_RE, SHORT_NUM, SHORT_SQ_RE
true
else
@@ -108,12 +114,8 @@ class Thor
end
end
- def current_is_switch_formatted?
- switch_formatted? peek
- end
-
def switch?(arg)
- switch_option(arg) || @shorts.key?(arg)
+ switch_option(normalize_switch(arg))
end
def switch_option(arg)
@@ -127,7 +129,7 @@ class Thor
# Check if the given argument is actually a shortcut.
#
def normalize_switch(arg)
- @shorts.key?(arg) ? @shorts[arg] : arg
+ (@shorts[arg] || arg).tr('_', '-')
end
# Parse boolean values which can be given as --foo=true, --foo or --no-foo.
@@ -169,6 +171,5 @@ class Thor
@non_assigned_required.delete(option)
send(:"parse_#{option.type}", switch)
end
-
end
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/rake_compat.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/rake_compat.rb
new file mode 100644
index 00000000..0d0757fd
--- /dev/null
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/rake_compat.rb
@@ -0,0 +1,66 @@
+require 'rake'
+
+class Thor
+ # Adds a compatibility layer to your Thor classes which allows you to use
+ # rake package tasks. For example, to use rspec rake tasks, one can do:
+ #
+ # require 'thor/rake_compat'
+ #
+ # class Default < Thor
+ # include Thor::RakeCompat
+ #
+ # Spec::Rake::SpecTask.new(:spec) do |t|
+ # t.spec_opts = ['--options', "spec/spec.opts"]
+ # t.spec_files = FileList['spec/**/*_spec.rb']
+ # end
+ # end
+ #
+ module RakeCompat
+ def self.rake_classes
+ @rake_classes ||= []
+ end
+
+ def self.included(base)
+ # Hack. Make rakefile point to invoker, so rdoc task is generated properly.
+ rakefile = File.basename(caller[0].match(/(.*):\d+/)[1])
+ Rake.application.instance_variable_set(:@rakefile, rakefile)
+ self.rake_classes << base
+ end
+ end
+end
+
+class Object #:nodoc:
+ alias :rake_task :task
+ alias :rake_namespace :namespace
+
+ def task(*args, &block)
+ task = rake_task(*args, &block)
+
+ if klass = Thor::RakeCompat.rake_classes.last
+ non_namespaced_name = task.name.split(':').last
+
+ description = non_namespaced_name
+ description << task.arg_names.map{ |n| n.to_s.upcase }.join(' ')
+ description.strip!
+
+ klass.desc description, task.comment || non_namespaced_name
+ klass.send :define_method, non_namespaced_name do |*args|
+ Rake::Task[task.name.to_sym].invoke(*args)
+ end
+ end
+
+ task
+ end
+
+ def namespace(name, &block)
+ if klass = Thor::RakeCompat.rake_classes.last
+ const_name = Thor::Util.camel_case(name.to_s).to_sym
+ klass.const_set(const_name, Class.new(Thor))
+ new_klass = klass.const_get(const_name)
+ Thor::RakeCompat.rake_classes << new_klass
+ end
+
+ rake_namespace(name, &block)
+ Thor::RakeCompat.rake_classes.pop
+ end
+end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/runner.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/runner.rb
new file mode 100644
index 00000000..0d9e3c05
--- /dev/null
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/runner.rb
@@ -0,0 +1,309 @@
+require 'thor'
+require 'thor/group'
+require 'thor/core_ext/file_binary_read'
+
+require 'fileutils'
+require 'open-uri'
+require 'yaml'
+require 'digest/md5'
+require 'pathname'
+
+class Thor::Runner < Thor #:nodoc:
+ map "-T" => :list, "-i" => :install, "-u" => :update, "-v" => :version
+
+ # Override Thor#help so it can give information about any class and any method.
+ #
+ def help(meth = nil)
+ if meth && !self.respond_to?(meth)
+ initialize_thorfiles(meth)
+ klass, task = Thor::Util.find_class_and_task_by_namespace(meth)
+ klass.start(["-h", task].compact, :shell => self.shell)
+ else
+ super
+ end
+ end
+
+ # If a task is not found on Thor::Runner, method missing is invoked and
+ # Thor::Runner is then responsable for finding the task in all classes.
+ #
+ def method_missing(meth, *args)
+ meth = meth.to_s
+ initialize_thorfiles(meth)
+ klass, task = Thor::Util.find_class_and_task_by_namespace(meth)
+ args.unshift(task) if task
+ klass.start(args, :shell => self.shell)
+ end
+
+ desc "install NAME", "Install an optionally named Thor file into your system tasks"
+ method_options :as => :string, :relative => :boolean, :force => :boolean
+ def install(name)
+ initialize_thorfiles
+
+ # If a directory name is provided as the argument, look for a 'main.thor'
+ # task in said directory.
+ begin
+ if File.directory?(File.expand_path(name))
+ base, package = File.join(name, "main.thor"), :directory
+ contents = open(base) {|input| input.read }
+ else
+ base, package = name, :file
+ contents = open(name) {|input| input.read }
+ end
+ rescue OpenURI::HTTPError
+ raise Error, "Error opening URI '#{name}'"
+ rescue Errno::ENOENT
+ raise Error, "Error opening file '#{name}'"
+ end
+
+ say "Your Thorfile contains:"
+ say contents
+
+ unless options["force"]
+ return false if no?("Do you wish to continue [y/N]?")
+ end
+
+ as = options["as"] || begin
+ first_line = contents.split("\n")[0]
+ (match = first_line.match(/\s*#\s*module:\s*([^\n]*)/)) ? match[1].strip : nil
+ end
+
+ unless as
+ basename = File.basename(name)
+ as = ask("Please specify a name for #{name} in the system repository [#{basename}]:")
+ as = basename if as.empty?
+ end
+
+ location = if options[:relative] || name =~ /^https?:\/\//
+ name
+ else
+ File.expand_path(name)
+ end
+
+ thor_yaml[as] = {
+ :filename => Digest::MD5.hexdigest(name + as),
+ :location => location,
+ :namespaces => Thor::Util.namespaces_in_content(contents, base)
+ }
+
+ save_yaml(thor_yaml)
+ say "Storing thor file in your system repository"
+ destination = File.join(thor_root, thor_yaml[as][:filename])
+
+ if package == :file
+ File.open(destination, "w") { |f| f.puts contents }
+ else
+ FileUtils.cp_r(name, destination)
+ end
+
+ thor_yaml[as][:filename] # Indicate success
+ end
+
+ desc "version", "Show Thor version"
+ def version
+ require 'thor/version'
+ say "Thor #{Thor::VERSION}"
+ end
+
+ desc "uninstall NAME", "Uninstall a named Thor module"
+ def uninstall(name)
+ raise Error, "Can't find module '#{name}'" unless thor_yaml[name]
+ say "Uninstalling #{name}."
+ FileUtils.rm_rf(File.join(thor_root, "#{thor_yaml[name][:filename]}"))
+
+ thor_yaml.delete(name)
+ save_yaml(thor_yaml)
+
+ puts "Done."
+ end
+
+ desc "update NAME", "Update a Thor file from its original location"
+ def update(name)
+ raise Error, "Can't find module '#{name}'" if !thor_yaml[name] || !thor_yaml[name][:location]
+
+ say "Updating '#{name}' from #{thor_yaml[name][:location]}"
+
+ old_filename = thor_yaml[name][:filename]
+ self.options = self.options.merge("as" => name)
+ filename = install(thor_yaml[name][:location])
+
+ unless filename == old_filename
+ File.delete(File.join(thor_root, old_filename))
+ end
+ end
+
+ desc "installed", "List the installed Thor modules and tasks"
+ method_options :internal => :boolean
+ def installed
+ initialize_thorfiles(nil, true)
+ display_klasses(true, options["internal"])
+ end
+
+ desc "list [SEARCH]", "List the available thor tasks (--substring means .*SEARCH)"
+ method_options :substring => :boolean, :group => :string, :all => :boolean, :debug => :boolean
+ def list(search="")
+ initialize_thorfiles
+
+ search = ".*#{search}" if options["substring"]
+ search = /^#{search}.*/i
+ group = options[:group] || "standard"
+
+ klasses = Thor::Base.subclasses.select do |k|
+ (options[:all] || k.group == group) && k.namespace =~ search
+ end
+
+ display_klasses(false, false, klasses)
+ end
+
+ private
+
+ def self.banner(task, all = false, subcommand = false)
+ "thor " + task.formatted_usage(self, all, subcommand)
+ end
+
+ def thor_root
+ Thor::Util.thor_root
+ end
+
+ def thor_yaml
+ @thor_yaml ||= begin
+ yaml_file = File.join(thor_root, "thor.yml")
+ yaml = YAML.load_file(yaml_file) if File.exists?(yaml_file)
+ yaml || {}
+ end
+ end
+
+ # Save the yaml file. If none exists in thor root, creates one.
+ #
+ def save_yaml(yaml)
+ yaml_file = File.join(thor_root, "thor.yml")
+
+ unless File.exists?(yaml_file)
+ FileUtils.mkdir_p(thor_root)
+ yaml_file = File.join(thor_root, "thor.yml")
+ FileUtils.touch(yaml_file)
+ end
+
+ File.open(yaml_file, "w") { |f| f.puts yaml.to_yaml }
+ end
+
+ def self.exit_on_failure?
+ true
+ end
+
+ # Load the thorfiles. If relevant_to is supplied, looks for specific files
+ # in the thor_root instead of loading them all.
+ #
+ # By default, it also traverses the current path until find Thor files, as
+ # described in thorfiles. This look up can be skipped by suppliying
+ # skip_lookup true.
+ #
+ def initialize_thorfiles(relevant_to=nil, skip_lookup=false)
+ thorfiles(relevant_to, skip_lookup).each do |f|
+ Thor::Util.load_thorfile(f, nil, options[:debug]) unless Thor::Base.subclass_files.keys.include?(File.expand_path(f))
+ end
+ end
+
+ # Finds Thorfiles by traversing from your current directory down to the root
+ # directory of your system. If at any time we find a Thor file, we stop.
+ #
+ # We also ensure that system-wide Thorfiles are loaded first, so local
+ # Thorfiles can override them.
+ #
+ # ==== Example
+ #
+ # If we start at /Users/wycats/dev/thor ...
+ #
+ # 1. /Users/wycats/dev/thor
+ # 2. /Users/wycats/dev
+ # 3. /Users/wycats <-- we find a Thorfile here, so we stop
+ #
+ # Suppose we start at c:\Documents and Settings\james\dev\thor ...
+ #
+ # 1. c:\Documents and Settings\james\dev\thor
+ # 2. c:\Documents and Settings\james\dev
+ # 3. c:\Documents and Settings\james
+ # 4. c:\Documents and Settings
+ # 5. c:\ <-- no Thorfiles found!
+ #
+ def thorfiles(relevant_to=nil, skip_lookup=false)
+ thorfiles = []
+
+ unless skip_lookup
+ Pathname.pwd.ascend do |path|
+ thorfiles = Thor::Util.globs_for(path).map { |g| Dir[g] }.flatten
+ break unless thorfiles.empty?
+ end
+ end
+
+ files = (relevant_to ? thorfiles_relevant_to(relevant_to) : Thor::Util.thor_root_glob)
+ files += thorfiles
+ files -= ["#{thor_root}/thor.yml"]
+
+ files.map! do |file|
+ File.directory?(file) ? File.join(file, "main.thor") : file
+ end
+ end
+
+ # Load thorfiles relevant to the given method. If you provide "foo:bar" it
+ # will load all thor files in the thor.yaml that has "foo" e "foo:bar"
+ # namespaces registered.
+ #
+ def thorfiles_relevant_to(meth)
+ lookup = [ meth, meth.split(":")[0...-1].join(":") ]
+
+ files = thor_yaml.select do |k, v|
+ v[:namespaces] && !(v[:namespaces] & lookup).empty?
+ end
+
+ files.map { |k, v| File.join(thor_root, "#{v[:filename]}") }
+ end
+
+ # Display information about the given klasses. If with_module is given,
+ # it shows a table with information extracted from the yaml file.
+ #
+ def display_klasses(with_modules=false, show_internal=false, klasses=Thor::Base.subclasses)
+ klasses -= [Thor, Thor::Runner, Thor::Group] unless show_internal
+
+ raise Error, "No Thor tasks available" if klasses.empty?
+ show_modules if with_modules && !thor_yaml.empty?
+
+ list = Hash.new { |h,k| h[k] = [] }
+ groups = klasses.select { |k| k.ancestors.include?(Thor::Group) }
+
+ # Get classes which inherit from Thor
+ (klasses - groups).each { |k| list[k.namespace.split(":").first] += k.printable_tasks(false) }
+
+ # Get classes which inherit from Thor::Base
+ groups.map! { |k| k.printable_tasks(false).first }
+ list["root"] = groups
+
+ # Order namespaces with default coming first
+ list = list.sort{ |a,b| a[0].sub(/^default/, '') <=> b[0].sub(/^default/, '') }
+ list.each { |n, tasks| display_tasks(n, tasks) unless tasks.empty? }
+ end
+
+ def display_tasks(namespace, list) #:nodoc:
+ list.sort!{ |a,b| a[0] <=> b[0] }
+
+ say shell.set_color(namespace, :blue, true)
+ say "-" * namespace.size
+
+ print_table(list, :truncate => true)
+ say
+ end
+
+ def show_modules #:nodoc:
+ info = []
+ labels = ["Modules", "Namespaces"]
+
+ info << labels
+ info << [ "-" * labels[0].size, "-" * labels[1].size ]
+
+ thor_yaml.each do |name, hash|
+ info << [ name, hash[:namespaces].join(", ") ]
+ end
+
+ print_table info
+ say ""
+ end
+end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell/basic.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell/basic.rb
old mode 100755
new mode 100644
similarity index 89%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell/basic.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell/basic.rb
index b227b5f4..c8411d3d
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell/basic.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell/basic.rb
@@ -11,6 +11,21 @@ class Thor
@base, @padding = nil, 0
end
+ # Mute everything that's inside given block
+ #
+ def mute
+ @mute = true
+ yield
+ ensure
+ @mute = false
+ end
+
+ # Check if base is muted
+ #
+ def mute?
+ @mute
+ end
+
# Sets the output padding, not allowing less than zero values.
#
def padding=(value)
@@ -24,7 +39,7 @@ class Thor
#
def ask(statement, color=nil)
say("#{statement} ", color)
- $stdin.gets.strip
+ stdin.gets.strip
end
# Say (print) something to the user. If the sentence ends with a whitespace
@@ -41,11 +56,11 @@ class Thor
spaces = " " * padding
if force_new_line
- $stdout.puts(spaces + message)
+ stdout.puts(spaces + message)
else
- $stdout.print(spaces + message)
+ stdout.print(spaces + message)
end
- $stdout.flush
+ stdout.flush
end
# Say a status with the given color and appends the message. Since this
@@ -61,15 +76,15 @@ class Thor
status = status.to_s.rjust(12)
status = set_color status, color, true if color
- $stdout.puts "#{status}#{spaces}#{message}"
- $stdout.flush
+ stdout.puts "#{status}#{spaces}#{message}"
+ stdout.flush
end
# Make a question the to user and returns true if the user replies "y" or
# "yes".
#
def yes?(statement, color=nil)
- ask(statement, color) =~ is?(:yes)
+ !!(ask(statement, color) =~ is?(:yes))
end
# Make a question the to user and returns true if the user replies "n" or
@@ -113,7 +128,7 @@ class Thor
end
sentence = truncate(sentence, options[:truncate]) if options[:truncate]
- $stdout.puts sentence
+ stdout.puts sentence
end
end
@@ -139,9 +154,9 @@ class Thor
paras.each do |para|
para.split("\n").each do |line|
- $stdout.puts line.insert(0, " " * ident)
+ stdout.puts line.insert(0, " " * ident)
end
- $stdout.puts unless para == paras.last
+ stdout.puts unless para == paras.last
end
end
@@ -180,12 +195,12 @@ class Thor
end
# Called if something goes wrong during the execution. This is used by Thor
- # internally and should not be used inside your scripts. If someone went
+ # internally and should not be used inside your scripts. If something went
# wrong, you can always raise an exception. If you raise a Thor::Error, it
# will be rescued and wrapped in the method below.
#
def error(statement)
- $stderr.puts statement
+ stderr.puts statement
end
# Apply color to the given string with optional bold. Disabled in the
@@ -197,6 +212,18 @@ class Thor
protected
+ def stdout
+ $stdout
+ end
+
+ def stdin
+ $stdin
+ end
+
+ def stderr
+ $stderr
+ end
+
def is?(value) #:nodoc:
value = value.to_s
@@ -229,7 +256,7 @@ HELP
end
def quiet? #:nodoc:
- base && base.options[:quiet]
+ mute? || (base && base.options[:quiet])
end
# This code was copied from Rake, available under MIT-LICENSE
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell/color.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell/color.rb
old mode 100755
new mode 100644
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell/color.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell/color.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell/html.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell/html.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/shell/html.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/shell/html.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/task.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/task.rb
old mode 100755
new mode 100644
similarity index 94%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/task.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/task.rb
index a4355831..6db3b608
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/task.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/task.rb
@@ -65,10 +65,9 @@ class Thor
@required_options ||= options.map{ |_, o| o.usage if o.required? }.compact.sort.join(" ")
end
- # Given a target, checks if this class name is not a private/protected method.
+ # Given a target, checks if this class name is a public method.
def public_method?(instance) #:nodoc:
- collection = instance.private_methods + instance.protected_methods
- (collection & [name.to_s, name.to_sym]).empty?
+ !(instance.public_methods & [name.to_s, name.to_sym]).empty?
end
def sans_backtrace(backtrace, caller) #:nodoc:
@@ -111,4 +110,4 @@ class Thor
end
end
end
-end
\ No newline at end of file
+end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/util.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/util.rb
old mode 100755
new mode 100644
similarity index 98%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/util.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/util.rb
index 7f2142b4..275a30bf
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vendor/thor/util.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/util.rb
@@ -8,11 +8,11 @@ class Thor
#
# 1) Methods to convert thor namespaces to constants and vice-versa.
#
- # Thor::Utils.namespace_from_thor_class(Foo::Bar::Baz) #=> "foo:bar:baz"
+ # Thor::Util.namespace_from_thor_class(Foo::Bar::Baz) #=> "foo:bar:baz"
#
# 2) Loading thor files and sandboxing:
#
- # Thor::Utils.load_thorfile("~/.thor/foo")
+ # Thor::Util.load_thorfile("~/.thor/foo")
#
module Util
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/version.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/version.rb
new file mode 100644
index 00000000..7de92f16
--- /dev/null
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendor/thor/version.rb
@@ -0,0 +1,3 @@
+class Thor
+ VERSION = "0.14.6".freeze
+end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendored_thor.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendored_thor.rb
new file mode 100644
index 00000000..bd837ba9
--- /dev/null
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vendored_thor.rb
@@ -0,0 +1,7 @@
+if defined?(Thor)
+ Bundler.ui.warn "Thor has already been required. " +
+ "This may cause Bundler to malfunction in unexpected ways."
+end
+$:.unshift File.expand_path('../vendor', __FILE__)
+require 'thor'
+require 'thor/actions'
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/version.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/version.rb
similarity index 74%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/version.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/version.rb
index 9f8590d5..e2303c16 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/version.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/version.rb
@@ -2,5 +2,5 @@ module Bundler
# We're doing this because we might write tests that deal
# with other versions of bundler and we are unsure how to
# handle this better.
- VERSION = "1.0.15" unless defined?(::Bundler::VERSION)
+ VERSION = "1.0.18" unless defined?(::Bundler::VERSION)
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vlad.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vlad.rb
similarity index 87%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vlad.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vlad.rb
index 023bde2d..47d35b13 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/lib/bundler/vlad.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/lib/bundler/vlad.rb
@@ -4,6 +4,8 @@
# include the vlad:bundle:install task in your vlad:deploy task.
require 'bundler/deployment'
+include Rake::DSL if defined? Rake::DSL
+
namespace :vlad do
Bundler::Deployment.define_task(Rake::RemoteTask, :remote_task, :roles => :app)
end
\ No newline at end of file
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-config.ronn b/vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-config.ronn
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-config.ronn
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-config.ronn
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-exec.ronn b/vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-exec.ronn
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-exec.ronn
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-exec.ronn
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-install.ronn b/vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-install.ronn
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-install.ronn
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-install.ronn
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-package.ronn b/vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-package.ronn
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-package.ronn
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-package.ronn
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-update.ronn b/vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-update.ronn
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle-update.ronn
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle-update.ronn
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle.ronn b/vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle.ronn
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/bundle.ronn
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/bundle.ronn
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/gemfile.5.ronn b/vendor/plugins/bundler/gems/bundler-1.0.18/man/gemfile.5.ronn
similarity index 98%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/gemfile.5.ronn
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/gemfile.5.ronn
index a8809b7a..d97dadc2 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/man/gemfile.5.ronn
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/man/gemfile.5.ronn
@@ -55,6 +55,9 @@ This defaults to the name of the gem itself. For instance, these are identical:
gem "nokogiri"
gem "nokogiri", :require => "nokogiri"
+Specify `:require => false` to prevent bundler from requiring the gem, but still
+install it and maintain dependencies.
+
### GROUPS (:group or :groups)
Each _gem_ `MAY` specify membership in one or more groups. Any _gem_ that does
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/man/index.txt b/vendor/plugins/bundler/gems/bundler-1.0.18/man/index.txt
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/man/index.txt
rename to vendor/plugins/bundler/gems/bundler-1.0.18/man/index.txt
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/gems_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/gems_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/gems_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/gems_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/git_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/git_spec.rb
similarity index 55%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/git_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/git_spec.rb
index 8c9055e7..42c3ad57 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/git_spec.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/git_spec.rb
@@ -4,6 +4,9 @@ describe "bundle cache with git" do
source = Bundler::Source::Git.new("uri" => "git@github.com:bundler.git")
source.send(:base_name).should == "bundler"
end
-end
-
+ it "base_name should strip network share paths" do
+ source = Bundler::Source::Git.new("uri" => "//MachineName/ShareFolder")
+ source.send(:base_name).should == "ShareFolder"
+ end
+ end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/path_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/path_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/path_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/path_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/platform_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/platform_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/cache/platform_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/cache/platform_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/deploy_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/deploy_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/deploy_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/deploy_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/deprecated_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/deprecated_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/deprecated_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/deprecated_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/c_ext_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/c_ext_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/c_ext_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/c_ext_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/env_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/env_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/env_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/env_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/flex_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/flex_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/flex_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/flex_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/groups_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/groups_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/groups_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/groups_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/packed_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/packed_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/packed_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/packed_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/platform_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/platform_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/platform_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/platform_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/resolving_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/resolving_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/resolving_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/resolving_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/simple_case_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/simple_case_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/simple_case_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/simple_case_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/sudo_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/sudo_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/sudo_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/sudo_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/win32_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/win32_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gems/win32_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gems/win32_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gemspec_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gemspec_spec.rb
similarity index 85%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gemspec_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gemspec_spec.rb
index 90e9a2fe..dce8b16c 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/gemspec_spec.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/gemspec_spec.rb
@@ -22,6 +22,23 @@ describe "bundle install from an existing gemspec" do
should_be_installed "bar-dev 1.0.0", :groups => :development
end
+ it "that is hidden should install runtime and development dependencies" do
+ build_lib("foo", :path => tmp.join("foo")) do |s|
+ s.write("Gemfile", "source :rubygems\ngemspec")
+ s.add_dependency "bar", "=1.0.0"
+ s.add_development_dependency "bar-dev", '=1.0.0'
+ end
+ FileUtils.mv tmp.join('foo', 'foo.gemspec'), tmp.join('foo', '.gemspec')
+
+ install_gemfile <<-G
+ source "file://#{gem_repo2}"
+ gemspec :path => '#{tmp.join("foo")}'
+ G
+
+ should_be_installed "bar 1.0.0"
+ should_be_installed "bar-dev 1.0.0", :groups => :development
+ end
+
it "should handle a list of requirements" do
build_gem "baz", "1.0", :to_system => true
build_gem "baz", "1.1", :to_system => true
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/git_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/git_spec.rb
similarity index 99%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/git_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/git_spec.rb
index 62cb887d..da2e886e 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/git_spec.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/git_spec.rb
@@ -403,7 +403,7 @@ describe "bundle install with git sources" do
gem "has_submodule"
end
G
- out.should =~ /Could not find gem 'submodule'/
+ out.should =~ /could not find gem 'submodule'/i
should_not_be_installed "has_submodule 1.0", :expect_err => true
end
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/invalid_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/invalid_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/invalid_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/invalid_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/path_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/path_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/path_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/path_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/upgrade_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/upgrade_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/install/upgrade_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/install/upgrade_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/lock/git_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/lock/git_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/lock/git_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/lock/git_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/lock/lockfile_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/lock/lockfile_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/lock/lockfile_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/lock/lockfile_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/check_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/check_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/check_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/check_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/config_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/config_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/config_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/config_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/console_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/console_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/console_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/console_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/exec_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/exec_spec.rb
similarity index 97%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/exec_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/exec_spec.rb
index 8f38824b..94e6408f 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/exec_spec.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/exec_spec.rb
@@ -101,7 +101,7 @@ describe "bundle exec" do
bundle "exec foobarbaz", :exitstatus => true
exitstatus.should eq(127)
out.should include("bundler: command not found: foobarbaz")
- out.should include("Install missing gem binaries with `bundle install`")
+ out.should include("Install missing gem executables with `bundle install`")
end
it "errors nicely when the argument is not executable" do
@@ -115,7 +115,7 @@ describe "bundle exec" do
out.should include("bundler: not executable: ./foo")
end
- describe "with gem binaries" do
+ describe "with gem executables" do
describe "run from a random directory" do
before(:each) do
install_gemfile <<-G
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/ext_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/ext_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/ext_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/ext_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/gem_helper_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/gem_helper_spec.rb
similarity index 92%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/gem_helper_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/gem_helper_spec.rb
index 1d05e8ea..bb21b60c 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/gem_helper_spec.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/gem_helper_spec.rb
@@ -10,6 +10,14 @@ describe "Bundler::GemHelper tasks" do
helper.gemspec.name.should == 'test'
end
+ it "interpolates the name for a hidden gemspec" do
+ bundle 'gem test'
+ app = bundled_app("test")
+ FileUtils.mv app.join('test.gemspec'), app.join('.gemspec')
+ helper = Bundler::GemHelper.new(app.to_s)
+ helper.gemspec.name.should == 'test'
+ end
+
it "should fail when there is no gemspec" do
bundle 'gem test'
app = bundled_app("test")
@@ -118,7 +126,7 @@ describe "Bundler::GemHelper tasks" do
`git config user.name "name"`
`git remote add origin file://#{gem_repo1}`
`git commit -a -m "initial commit"`
- Open3.popen3("git push origin master") # use popen3 to silence output...
+ sys_exec("git push origin master", true)
`git commit -a -m "another commit"`
}
@helper.release_gem
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/help_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/help_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/help_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/help_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/init_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/init_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/init_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/init_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/newgem_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/newgem_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/newgem_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/newgem_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/open_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/open_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/open_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/open_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/show_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/show_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/other/show_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/other/show_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/quality_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/quality_spec.rb
similarity index 95%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/quality_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/quality_spec.rb
index 9b84be4b..ee097ea0 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/quality_spec.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/quality_spec.rb
@@ -1,5 +1,9 @@
require "spec_helper"
+if defined?(Encoding)
+ Encoding.default_external = "UTF-8"
+end
+
describe "The library itself" do
def check_for_tab_characters(filename)
failing_lines = []
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/resolver/basic_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/resolver/basic_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/resolver/basic_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/resolver/basic_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/resolver/platform_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/resolver/platform_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/resolver/platform_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/resolver/platform_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/executable_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/executable_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/executable_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/executable_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/load_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/load_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/load_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/load_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/platform_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/platform_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/platform_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/platform_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/require_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/require_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/require_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/require_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/setup_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/setup_spec.rb
similarity index 99%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/setup_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/setup_spec.rb
index e2d94e23..44d43370 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/setup_spec.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/setup_spec.rb
@@ -214,7 +214,7 @@ describe "Bundler.setup" do
out.should == "WIN"
end
- it "version_requirement is now deprecated in rubygesm 1.4.0+ when the version is wrong" do
+ it "version_requirement is now deprecated in rubygems 1.4.0+ when the version is wrong" do
run <<-R, :expect_err => true
begin
gem "rack", "1.0.0"
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/with_clean_env_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/with_clean_env_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/runtime/with_clean_env_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/runtime/with_clean_env_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/spec_helper.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/spec_helper.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/spec_helper.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/spec_helper.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/builders.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/builders.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/builders.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/builders.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/helpers.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/helpers.rb
similarity index 99%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/helpers.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/helpers.rb
index 90a82c99..d21e85a2 100644
--- a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/helpers.rb
+++ b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/helpers.rb
@@ -13,7 +13,7 @@ module Spec
FileUtils.mkdir_p(tmp)
FileUtils.mkdir_p(home)
Gem.sources = ["file://#{gem_repo1}/"]
- Gem.configuration.write
+ # Gem.configuration.write
end
attr_reader :out, :err, :exitstatus
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/indexes.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/indexes.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/indexes.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/indexes.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/matchers.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/matchers.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/matchers.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/matchers.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/path.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/path.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/path.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/path.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/platforms.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/platforms.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/platforms.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/platforms.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/ruby_ext.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/ruby_ext.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/ruby_ext.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/ruby_ext.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/rubygems_ext.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/rubygems_ext.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/rubygems_ext.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/rubygems_ext.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/rubygems_hax/platform.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/rubygems_hax/platform.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/rubygems_hax/platform.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/rubygems_hax/platform.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/sudo.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/sudo.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/support/sudo.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/support/sudo.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/update/gems_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/update/gems_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/update/gems_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/update/gems_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/update/git_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/update/git_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/update/git_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/update/git_spec.rb
diff --git a/vendor/plugins/bundler/gems/bundler-1.0.15/spec/update/source_spec.rb b/vendor/plugins/bundler/gems/bundler-1.0.18/spec/update/source_spec.rb
similarity index 100%
rename from vendor/plugins/bundler/gems/bundler-1.0.15/spec/update/source_spec.rb
rename to vendor/plugins/bundler/gems/bundler-1.0.18/spec/update/source_spec.rb