diff --git a/ext/WarMain.java b/ext/WarMain.java
index 6832e789..fdb55915 100644
--- a/ext/WarMain.java
+++ b/ext/WarMain.java
@@ -241,7 +241,7 @@ protected int launchJRuby(final URL[] jars) throws Exception {
invokeMethod(rubyInstanceConfig, "setUpdateNativeENVEnabled", new Class[] { Boolean.TYPE }, false);
- final CharSequence execScriptEnvPre = executableScriptEnvPrefix();
+ final CharSequence execScriptEnvPre = "require File.expand_path('META-INF/init.rb')";
final String executablePath = locateExecutable(scriptingContainer, execScriptEnvPre);
if ( executablePath == null ) {
@@ -267,21 +267,6 @@ protected int launchJRuby(final URL[] jars) throws Exception {
return ( outcome instanceof Number ) ? ( (Number) outcome ).intValue() : 0;
}
- @Deprecated
- protected String locateExecutable(final Object scriptingContainer) throws Exception {
- if ( executable == null ) {
- throw new IllegalStateException("no executable");
- }
- final File exec = new File(extractRoot, executable);
- if ( exec.exists() ) {
- return exec.getAbsolutePath();
- }
- else {
- final String script = locateExecutableScript(executable, executableScriptEnvPrefix());
- return (String) invokeMethod(scriptingContainer, "runScriptlet", script);
- }
- }
-
protected String locateExecutable(final Object scriptingContainer, final CharSequence envPreScript)
throws Exception {
if ( executable == null ) {
@@ -297,18 +282,6 @@ protected String locateExecutable(final Object scriptingContainer, final CharSeq
}
}
- protected CharSequence executableScriptEnvPrefix() {
- final String gemsDir = new File(extractRoot, "gems").getAbsolutePath();
- final String gemfile = new File(extractRoot, "Gemfile").getAbsolutePath();
- debug("setting GEM_HOME to " + gemsDir);
- debug("... and BUNDLE_GEMFILE to " + gemfile);
-
- // ideally this would look up the config.override_gem_home setting
- return "ENV['GEM_HOME'] = ENV['GEM_PATH'] = '"+ gemsDir +"' \n" +
- "ENV['BUNDLE_GEMFILE'] ||= '"+ gemfile +"' \n" +
- "require 'uri:classloader:/META-INF/init.rb'";
- }
-
protected String locateExecutableScript(final String executable, final CharSequence envPreScript) {
return ( envPreScript == null ? "" : envPreScript + " \n" ) +
"begin\n" + // locate the executable within gemspecs :
diff --git a/lib/warbler/templates/jar.erb b/lib/warbler/templates/jar.erb
index 5bc33849..a931210b 100644
--- a/lib/warbler/templates/jar.erb
+++ b/lib/warbler/templates/jar.erb
@@ -7,5 +7,5 @@ ENV['GEM_HOME'] <%= config.override_gem_home ? '=' : '||=' %> File.expand_path(F
ENV['GEM_PATH'] = nil # RGs sets Gem.paths.path = Gem.default_path + [ GEM_HOME ]
<% end -%>
<% if config.bundler && config.bundler[:gemfile_path] -%>
-ENV['BUNDLE_GEMFILE'] = File.expand_path(File.join('..', '..', '<%= config.bundler[:gemfile_path] %>'), __FILE__)
+ENV['BUNDLE_GEMFILE'] ||= File.expand_path(File.join('..', '..', '<%= config.bundler[:gemfile_path] %>'), __FILE__)
<% end -%>
diff --git a/lib/warbler/templates/war.erb b/lib/warbler/templates/war.erb
index 6f141f6d..7457dd14 100644
--- a/lib/warbler/templates/war.erb
+++ b/lib/warbler/templates/war.erb
@@ -1,15 +1,12 @@
+<% gem_operator = config.override_gem_home ? '=' : '||=' %>
if $servlet_context.nil?
- ENV['GEM_HOME'] <%= config.override_gem_home ? '=' : '||=' %> File.expand_path(File.join('..', '..', '<%= config.gem_path %>'), __FILE__)
-<% if config.override_gem_home -%>
-<% # GEM_HOME/GEM_PATH are set as .war gets extracted (on java -jar ...)
- # ... thus setting `ENV['GEM_PATH'] = nil` would cause a boot failure
--%>
-<% end -%>
+ ENV['GEM_HOME'] <%= gem_operator %> File.expand_path(File.join('..', '..', '<%= config.gem_path %>'), __FILE__).sub('/WEB-INF/', '/')
+ ENV['GEM_PATH'] <%= gem_operator %> ENV['GEM_HOME']
<% if config.bundler && config.bundler[:gemfile_path] -%>
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path(File.join('..', '..', '<%= config.bundler[:gemfile_path] %>'), __FILE__)
+ ENV['BUNDLE_GEMFILE'] ||= File.expand_path(File.join('..', '..', '<%= config.bundler[:gemfile_path] %>'), __FILE__).sub('/WEB-INF/', '/')
<% end -%>
else
- ENV['GEM_HOME'] <%= config.override_gem_home ? '=' : '||=' %> $servlet_context.getRealPath('<%= config.gem_path %>')
+ ENV['GEM_HOME'] <%= gem_operator %> $servlet_context.getRealPath('<%= config.gem_path %>')
<% if config.override_gem_home -%>
ENV['GEM_PATH'] = nil
<% end -%>
diff --git a/spec/sample_bundler/Special-Gemfile b/spec/sample_bundler/Special-Gemfile
new file mode 100644
index 00000000..0847a0a2
--- /dev/null
+++ b/spec/sample_bundler/Special-Gemfile
@@ -0,0 +1,3 @@
+source "https://rubygems.org"
+
+gem 'rake', '12.3.1'
diff --git a/spec/sample_bundler/Special-Gemfile.lock b/spec/sample_bundler/Special-Gemfile.lock
new file mode 100644
index 00000000..afa0f58d
--- /dev/null
+++ b/spec/sample_bundler/Special-Gemfile.lock
@@ -0,0 +1,13 @@
+GEM
+ remote: https://rubygems.org/
+ specs:
+ rake (12.3.1)
+
+PLATFORMS
+ java
+
+DEPENDENCIES
+ rake (= 12.3.1)
+
+BUNDLED WITH
+ 1.16.4
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/bin/rake b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/bin/rake
index e5a537e5..bb5b395d 100755
--- a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/bin/rake
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/bin/rake
@@ -19,4 +19,9 @@ if ARGV.first
end
end
+if Gem.respond_to?(:activate_bin_path)
load Gem.activate_bin_path('rake', 'rake', version)
+else
+gem "rake", version
+load Gem.bin_path("rake", "rake", version)
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/cache/rake-12.3.1.gem b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/cache/rake-12.3.1.gem
new file mode 100644
index 00000000..ea34ea6f
Binary files /dev/null and b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/cache/rake-12.3.1.gem differ
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/.gitignore b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/.gitignore
new file mode 100644
index 00000000..f0cd1f57
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/.gitignore
@@ -0,0 +1,14 @@
+*.bak
+*.rbc
+*.swp
+*~
+.#*
+.DS_Store
+.idea
+.rbx
+/.rdoc
+/TAGS
+/coverage
+/html
+/pkg
+Gemfile.lock
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/CONTRIBUTING.rdoc b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/CONTRIBUTING.rdoc
new file mode 100644
index 00000000..d68e8c52
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/CONTRIBUTING.rdoc
@@ -0,0 +1,36 @@
+= Source Repository
+
+Rake is currently hosted at github. The github web page is
+https://github.com/ruby/rake . The public git clone URL is
+
+ git://github.com/ruby/rake.git
+
+= Running the Rake Test Suite
+
+If you wish to run the unit and functional tests that come with Rake:
+
+* +cd+ into the top project directory of rake.
+* Install gem dependency using bundler:
+
+ bundle install # Install bundler, minitest and rdoc
+
+* Type one of the following:
+
+ rake # If you have run rake's tests
+
+= Issues and Bug Reports
+
+Feel free to submit commits or feature requests. If you send a patch,
+remember to update the corresponding unit tests. In fact, I prefer
+new feature to be submitted in the form of new unit tests.
+
+For other information, feel free to ask on the ruby-talk mailing list.
+
+If you have found a bug in rake please try with the latest version of rake
+before filing an issue. Also check History.rdoc for bug fixes that may have
+addressed your issue.
+
+When submitting pull requests please check the rake Travis-CI page for test
+failures:
+
+ https://travis-ci.org/ruby/rake
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/Gemfile b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/Gemfile
new file mode 100644
index 00000000..b4e2a20b
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/Gemfile
@@ -0,0 +1,3 @@
+source "https://rubygems.org"
+
+gemspec
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/History.rdoc b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/History.rdoc
new file mode 100644
index 00000000..2ae9ba76
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/History.rdoc
@@ -0,0 +1,2317 @@
+=== 12.3.1
+
+==== Bug fixes
+
+* Support did_you_mean >= v1.2.0 which has a breaking change on formatters.
+ Pull request #262 by FUJI Goro.
+
+==== Enhancements:
+
+* Don't run task if it depends on already invoked but failed task.
+ Pull request #252 by Gonzalo Rodriguez.
+* Make space trimming consistent for all task arguments.
+ Pull request #259 by Gonzalo Rodriguez.
+* Removes duplicated inclusion of Rake::DSL in tests.
+ Pull request #254 by Gonzalo Rodriguez.
+* Re-raise a LoadError that didn't come from require in the test loader.
+ Pull request #250 by Dylan Thacker-Smith.
+
+=== 12.3.0
+
+==== Compatibility Changes
+
+* Bump `required_ruby_version` to Ruby 2.0.0. Rake has already
+ removed support for Ruby 1.9.x.
+
+==== Enhancements:
+
+* Support `test-bundled-gems` task on ruby core.
+
+=== 12.2.1
+
+==== Bug fixes
+
+* Fixed to break Capistrano::Application on capistrano3.
+
+=== 12.2.0
+
+==== Enhancements:
+
+* Make rake easier to use as a library
+ Pull request #211 by @drbrain
+* Fix quadratic performance in FileTask#out_of_date?
+ Pull request #224 by @doudou
+* Clarify output when printing nested exception traces
+ Pull request #232 by @urbanautomaton
+
+==== Bug fixes
+
+* Account for a file that match 2 or more patterns.
+ Pull request #231 by @styd
+
+=== 12.1.0
+
+==== Enhancements:
+
+* Added did_you_mean feature for invalid rake task.
+ Pull request #221 by @xtina-starr
+* Enabled to dependency chained by extensions. Pull request #39 by Petr Skocik.
+* Make all of string literals to frozen objects on Ruby 2.4 or later.
+
+==== Bug fixes
+
+* Typo fixes in rakefile.rdoc. Pull request #180 by Yuta Kurotaki.
+* Fix unexpected behavior of file task with dryrun option.
+ Pull request #183 by @aycabta.
+* Make LoadError from running tests more obvious. Pull request #195
+ by Eric Hodel.
+* Fix unexpected TypeError with hash style option. Pull request #202
+ by Kuniaki IGARASHI.
+
+=== 12.0.0
+
+==== Compatibility Changes
+
+* Removed arguments on clear #157 by Jesse Bowes
+* Removed `rake/contrib` packages. These are extracted to `rake-contrib` gem.
+* Removed deprecated method named `last\_comment`.
+
+==== Enhancements:
+
+* Re-use trace option on `cleanup` task. #164 by Brian Henderson
+* Actions adore keyword arguments #174 by Josh Cheek
+* Rake::TaskArguments#key? alias of #has_key? #175 by Paul Annesley
+
+=== 11.3.0 / 2016-09-20
+
+==== Enhancements:
+
+* Remove to reference `Fixnum` constant. Pull request #160 by nobu
+
+=== 11.2.2 / 2016-06-12
+
+==== Bug fixes
+
+* Fix unexpected behavior with multiple dependencies on Rake::TestTask
+
+=== 11.2.1 / 2016-06-12
+
+==== Bug fixes
+
+* Fix regression of dependencies handling on Rake::TestTask. Report #139
+
+=== 11.2.0 / 2016-06-11
+
+==== Bug fixes
+
+* Fix unexpected cut-out behavior on task description using triple dots
+ and exclamation. Report #106 from Stephan Kämper and Pull request #134 by Lee
+* Fix empty argument assignment with `with_defaults` option. Pull request #135
+ by bakunyo
+* Ignore to use `hwprefs` on Darwin platform. Use sysctl now. Report #128
+
+==== Enhancements
+
+* Spawn options for sh Pull equest #138 by Eric Hodel.
+* Allow to specify dependencies(prerequisites) for Rake::TestTask
+ Pull request #117 by Tim Maslyuchenko
+* Use Bundler task instead of hoe for gem release.
+* Remove explicitly load to rubygems for Ruby 1.8.
+* Unify to declare `Rake::VERSION`.
+* Support xz format for PackageTask.
+
+=== 11.1.2 / 2016-03-28
+
+==== Bug fixes
+
+* Remove `-W` option when Rake::TestTask#verbose enabled. It's misunderstanding
+ specification change with Rake 11. Partly revert #67
+
+=== 11.1.1 / 2016-03-14
+
+==== Bug fixes
+
+* Use `-W` instead of `--verbose` when Rake::TestTask#verbose enabled.
+ JRuby doesn't have `--verbose` option.
+
+=== 11.1.0 / 2016-03-11
+
+==== Compatibility Changes
+
+* Revert to remove `last\_comment`. It will remove Rake 12.
+
+=== 11.0.1 / 2016-03-09
+
+==== Bug fixes
+
+* Fixed packaging manifest.
+
+=== 11.0.0 / 2016-03-09
+
+==== Bug fixes
+
+* Correctly handle bad encoding in exception messages. Pull request #113
+ by Tomer Brisker
+* Fix verbose option at TestTask. Pull request #67 by Mike Blumtritt
+
+==== Enhancements
+
+* Make FileList#exclude more analogous to FileList#include.
+* Use IO.open instead of Open3.popen3 for CPU counter.
+* Make Rake::Task#already_invoked publicly accessible.
+ Pull request #93 by Joe Rafaniello
+* Lookup prerequisites with same name outside of scope instead of
+ matching self. Pull request #96 by Sandy Vanderbleek
+* Make FileList#pathmap behave like String#pathmap.
+ Pull request #61 by Daniel Tamai
+* Add fetch method to task arguments.
+ Pull request #12 by Chris Keathley
+* Use ruby warnings by default. Pull request #97 by Harold Giménez
+
+==== Compatibility Changes
+
+* Removed to support Ruby 1.8.x
+* Removed constant named `RAKEVERSION`
+* Removed Rake::AltSystem
+* Removed Rake::RubyForgePublisher
+* Removed Rake::TaskManager#last\_comment. Use last\_description.
+* Removed Rake::TaskLib#paste
+* Removed Top-level SshDirPublisher, SshFreshDirPublisher, SshFilePublisher
+ and CompositePublisher from lib/rake/contrib/publisher.rb
+* Removed "rake/runtest.rb"
+
+=== 10.5.0 / 2016-01-13
+
+==== Enhancements
+
+* Removed monkey patching for Ruby 1.8. Pull request #46 by Pablo Herrero.
+* Inheritance class of Rake::FileList returns always self class.
+ Pull request #74 by Thomas Scholz
+
+=== 10.4.2 / 2014-12-02
+
+==== Bug fixes
+
+* Rake no longer edits ARGV. This allows you to re-exec rake from a rake
+ task. Pull requset #9 by Matt Palmer.
+* Documented how Rake::DSL#desc handles sentences in task descriptions.
+ Issue #7 by Raza Sayed.
+* Fixed test error on 1.9.3 with legacy RubyGems. Issue #8 by Matt Palmer.
+* Deleted duplicated History entry. Pull request #10 by Yuji Yamamoto.
+
+=== 10.4.1 / 2014-12-01
+
+==== Bug fixes
+
+* Reverted fix for #277 as it caused numerous issues for rake users.
+ rails/spring issue #366 by Gustavo Dutra.
+
+=== 10.4.0 / 2014-11-22
+
+==== Enhancements
+
+* Upgraded to minitest 5. Pull request #292 by Teo Ljungberg.
+* Added support for Pathname in rake tasks. Pull request #271 by Randy
+ Coulman.
+* Rake now ignores falsy dependencies which allows for easier programmatic
+ creation of tasks. Pull request #273 by Manav.
+* Rake no longer edits ARGV. This allows you to re-exec rake from a rake
+ task. Issue #277 by Matt Palmer.
+* Etc.nprocessors is used for counting the number of CPUs.
+
+==== Bug fixes
+
+* Updated rake manpage. Issue #283 by Nathan Long, pull request #291 by
+ skittleys.
+* Add Rake::LATE to allow rebuilding of files that depend on deleted files.
+ Bug #286, pull request #287 by David Grayson.
+* Fix relinking of files when repackaging. Bug #276 by Muenze.
+* Fixed some typos. Pull request #280 by Jed Northridge.
+* Try counting CPUs via cpuinfo if host_os was not matched. Pull request
+ #282 by Edouard B.
+
+=== 10.3.2 / 2014-05-15
+
+==== Bug fixes
+
+* Rake no longer infinitely loops when showing exception causes that refer to
+ each other. Bug #272 by Chris Bandy.
+* Fixed documentation typos. Bug #275 by Jake Worth.
+
+=== 10.3.1 / 2014-04-17
+
+==== Bug fixes
+
+* Really stop reporting an error when cleaning already-deleted files. Pull
+ request #269 by Randy Coulman
+* Fixed infinite loop when cleaning already-deleted files on windows.
+
+=== 10.3 / 2014-04-15
+
+==== Enhancements
+
+* Added --build-all option to rake which treats all file prerequisites as
+ out-of-date. Pull request #254 by Andrew Gilbert.
+* Added Rake::NameSpace#scope. Issue #263 by Jon San Miguel.
+
+==== Bug fixes
+
+* Suppress org.jruby package files in rake error messages for JRuby users.
+ Issue #213 by Charles Nutter.
+* Fixed typo, removed extra "h". Pull request #267 by Hsing-Hui Hsu.
+* Rake no longer reports an error when cleaning already-deleted files. Pull
+ request #266 by Randy Coulman.
+* Consume stderr while determining CPU count to avoid hang. Issue #268 by
+ Albert Sun.
+
+=== 10.2.2 / 2014-03-27
+
+==== Bug fixes
+
+* Restored Ruby 1.8.7 compatibility
+
+=== 10.2.1 / 2014-03-25
+
+==== Bug fixes
+
+* File tasks including a ':' are now top-level tasks again. Issue #262 by
+ Josh Holtrop.
+* Use sysctl for CPU count for all BSDs. Pull request #261 by Joshua Stein.
+* Fixed CPU detection for unknown platforms.
+
+=== 10.2.0 / 2014-03-24
+
+==== Enhancements
+
+* Rake now requires Ruby 1.9 or newer. For me, this is a breaking change, but
+ it seems that Jim planned to release it with Rake 10.2. See also pull
+ request #247 by Philip Arndt.
+* Rake now allows you to declare tasks under a namespace like:
+
+ task 'a:b' do ... end
+
+ Pull request #232 by Judson Lester.
+* Task#source defaults to the first prerequisite in non-rule tasks. Pull
+ request #215 by Avdi Grimm.
+* Rake now automatically rebuilds and reloads imported files. Pull request
+ #209 by Randy Coulman.
+* The rake task arguments can contain escaped commas. Pull request #214 by
+ Filip Hrbek.
+* Rake now prints the exception class on errors. Patch #251 by David Cornu.
+
+==== Bug fixes
+
+* Fixed typos. Pull request #256 by Valera Rozuvan, #250 via Jake Worth, #260
+ by Zachary Scott.
+* Fixed documentation for calling tasks with arguments. Pull request #235 by
+ John Varghese.
+* Clarified `rake -f` usage message. Pull request #252 by Marco Pfatschbacher.
+* Fixed a test failure on windows. Pull request #231 by Hiroshi Shirosaki.
+* Fixed corrupted rake.1.gz. Pull request #225 by Michel Boaventura.
+* Fixed bug in can\_detect\_signals? in test. Patch from #243 by Alexey
+ Borzenkov.
+
+=== 10.1.1
+
+* Use http://github.com/jimweirich/rake instead of http://rake.rubyforge.org for
+ canonical project url.
+
+=== 10.1.0
+
+==== Changes
+
+===== New Features
+
+* Add support for variable length task argument lists. If more actual
+ arguments are supplied than named arguments, then the extra
+ arguments values will be in args.extras.
+
+* Application name is not displayed in the help banner. (Previously
+ "rake" was hardcoded, now rake-based applications can display their
+ own names).
+
+===== Bug Fixes
+
+Bug fixes include:
+
+* Fix backtrace suppression issues.
+
+* Rules now explicit get task arguments passed to them.
+
+* Rename FileList#exclude? to FileList#exclude\_from\_list? to avoid
+ conflict with new Rails method.
+
+* Clean / Clobber tasks now report failure to remove files.
+
+* Plus heaps of internal code cleanup.
+
+==== Thanks
+
+As usual, it was input from users that drove a lot of these changes.
+The following people contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Michael Nikitochkin (general code cleanup)
+* Vipul A M (general code cleanup)
+* Dennis Bell (variable length task argument lists)
+* Jacob Swanner (rules arguments)
+* Rafael Rosa Fu (documentation typo)
+* Stuart Nelson (install.rb fixes)
+* Lee Hambley (application name in help banner)
+
+-- Jim Weirich
+
+=== 10.0.3
+
+ "Jim, when will Rake reach version 1.0?"
+
+Over the past several years I've been asked that question at
+conferences, panels and over twitter. Due to historical reasons (or
+maybe just plain laziness) Rake has (incorrectly) been treating the
+second digit of the version as the major release number. So in my head
+Rake was already at version 9.
+
+Well, it's time to fix things. This next version of Rake drops old,
+crufty, backwards compatibility hacks such as top level constants, DSL
+methods defined in Object and numerous other features that are just no
+longer desired. It's also time to drop the leading zero from the
+version number as well and call this new version of rake what it
+really is: Version 10.
+
+So, welcome to Rake 10.0!
+
+Rake 10 is actually feature identical to the latest version of Rake 9
+(that would be the version spelled 0.9.3), *except* that Rake 10 drops
+all the sundry deprecated features that have accumulated over the years.
+
+If your Rakefile is up to date and current with all the new features
+of Rake 10, you are ready to go. If your Rakefile still uses a few
+deprecated feeatures, feel free to use Rake 9 (0.9.3) with the same
+feature set. Just be aware that future features will be in Rake 10
+family line.
+
+==== Changes
+
+As mentioned above, there are no new features in Rake 10. However,
+there are a number of features missing:
+
+* Classic namespaces are now gone. Rake is no longer able to reflect
+ the options settings in the global variables ($rakefile, $show\_tasks,
+ $show\_prereqs, $trace, $dryrun and $silent). The
+ --classic-namespace option is no longer supported.
+
+* Global constants are no longer supported. This includes
+ Task, FileTask, FileCreationTask and
+ RakeApp). The constant missing hook to warn about using
+ global rake constants has been removed.
+
+* The Rake DSL methods (task, file, directory, etc) are in their own
+ module (Rake::DSL). The stub versions of these methods (that printed
+ warnings) in Object have been removed. However, the DSL methods are
+ added to the top-level main object. Since main is
+ not in the inheritance tree, the presence of the DSL methods in main
+ should be low impact on other libraries.
+
+ If you want to use the Rake DSL commands from your own code, just
+ include Rake::DSL into your own classes and modules.
+
+* The deprecated syntax for task arguments (the one using
+ :needs) has been removed.
+
+* The --reduce-compat flag has been removed (it's not needed
+ anymore).
+
+* The deprecated rake/sys.rb library has been removed.
+
+* The deprecated rake/rdoctask.rb library has been removed.
+ RDoc supplies its own rake task now.
+
+* The deprecated rake/gempackagetask.rb library has been
+ removed. Gem supplies its own package task now.
+
+There is one small behavioral change:
+
+* Non-file tasks now always report the current time as their time
+ stamp. This is different from the previous behavior where non-file
+ tasks reported current time only if there were no prerequisites, and
+ the max prerequisite timestamp otherwise. This lead to inconsistent
+ and surprising behavior when adding prerequisites to tasks that in
+ turn were prequisites to file tasks. The new behavior is more
+ consistent and predictable.
+
+==== Changes (from 0.9.3, 0.9.4, 0.9.5)
+
+Since Rake 10 includes the changes from the last version of Rake 9,
+we'll repeat the changes for versions 0.9.3 through 0.9.5 here.
+
+===== New Features (in 0.9.3)
+
+* Multitask tasks now use a thread pool. Use -j to limit the number of
+ available threads.
+
+* Use -m to turn regular tasks into multitasks (use at your own risk).
+
+* You can now do "Rake.add_rakelib 'dir'" in your Rakefile to
+ programatically add rake task libraries.
+
+* You can specific backtrace suppression patterns (see
+ --suppress-backtrace)
+
+* Directory tasks can now take prerequisites and actions
+
+* Use --backtrace to request a full backtrace without the task trace.
+
+* You can say "--backtrace=stdout" and "--trace=stdout" to route trace
+ output to standard output rather than standard error.
+
+* Optional 'phony' target (enable with 'require 'rake/phony'") for
+ special purpose builds.
+
+* Task#clear now clears task comments as well as actions and
+ prerequisites. Task#clear_comment will specifically target comments.
+
+* The --all option will force -T and -D to consider all the tasks,
+ with and without descriptions.
+
+===== Bug Fixes (in 0.9.3)
+
+* Semi-colons in windows rakefile paths now work.
+
+* Improved Control-C support when invoking multiple test suites.
+
+* egrep method now reads files in text mode (better support for
+ Windows)
+
+* Better deprecation line number reporting.
+
+* The -W option now works with all tasks, whether they have a
+ description or not.
+
+* File globs in rake should not be sorted alphabetically, independent
+ of file system and platform.
+
+* Numerous internal improvements.
+
+* Documentation typos and fixes.
+
+===== Bug Fixes (in 0.9.4)
+
+* Exit status with failing tests is not correctly set to non-zero.
+
+* Simplified syntax for phony task (for older versions of RDoc).
+
+* Stand alone FileList usage gets glob function (without loading in
+ extra dependencies)
+
+===== Bug Fixes (in 0.9.5)
+
+* --trace and --backtrace no longer swallow following task names.
+
+==== Thanks
+
+As usual, it was input from users that drove a lot of these changes. The
+following people contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== 10.0.2
+
+==== Changes
+
+===== Bug Fixes
+
+* --trace and --backtrace no longer swallow following task names.
+
+==== Thanks
+
+As usual, it was input from users that drove a lot of these changes. The
+following people contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== 10.0.1
+
+==== Changes
+
+===== Bug Fixes
+
+* Exit status with failing tests is not correctly set to non-zero.
+
+* Simplified syntax for phony task (for older versions of RDoc).
+
+* Stand alone FileList usage gets glob function (without loading in
+ extra dependencies)
+
+==== Thanks
+
+As usual, it was input from users that drove a lot of these changes. The
+following people contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== 10.0.0
+
+ "Jim, when will Rake reach version 1.0?"
+
+Over the past several years I've been asked that question at
+conferences, panels and over twitter. Due to historical reasons (or
+maybe just plain laziness) Rake has (incorrectly) been treating the
+second digit of the version as the major release number. So in my head
+Rake was already at version 9.
+
+Well, it's time to fix things. This next version of Rake drops old,
+crufty, backwards compatibility hacks such as top level constants, DSL
+methods defined in Object and numerous other features that are just no
+longer desired. It's also time to drop the leading zero from the
+version number as well and call this new version of rake what it
+really is: Version 10.
+
+So, welcome to Rake 10.0!
+
+Rake 10 is actually feature identical to the latest version of Rake 9
+(that would be the version spelled 0.9.3), *except* that Rake 10 drops
+all the sundry deprecated features that have accumulated over the years.
+
+If your Rakefile is up to date and current with all the new features
+of Rake 10, you are ready to go. If your Rakefile still uses a few
+deprecated feeatures, feel free to use Rake 9 (0.9.3) with the same
+feature set. Just be aware that future features will be in Rake 10
+family line.
+
+==== Changes in 10.0
+
+As mentioned above, there are no new features in Rake 10. However,
+there are a number of features missing:
+
+* Classic namespaces are now gone. Rake is no longer able to reflect
+ the options settings in the global variables ($rakefile, $show\_tasks,
+ $show\_prereqs, $trace, $dryrun and $silent). The
+ --classic-namespace option is no longer supported.
+
+* Global constants are no longer supported. This includes
+ Task, FileTask, FileCreationTask and
+ RakeApp). The constant missing hook to warn about using
+ global rake constants has been removed.
+
+* The Rake DSL methods (task, file, directory, etc) are in their own
+ module (Rake::DSL). The stub versions of these methods (that printed
+ warnings) in Object have been removed. However, the DSL methods are
+ added to the top-level main object. Since main is
+ not in the inheritance tree, the presence of the DSL methods in main
+ should be low impact on other libraries.
+
+ If you want to use the Rake DSL commands from your own code, just
+ include Rake::DSL into your own classes and modules.
+
+* The deprecated syntax for task arguments (the one using
+ :needs) has been removed.
+
+* The --reduce-compat flag has been removed (it's not needed
+ anymore).
+
+* The deprecated rake/sys.rb library has been removed.
+
+* The deprecated rake/rdoctask.rb library has been removed.
+ RDoc supplies its own rake task now.
+
+* The deprecated rake/gempackagetask.rb library has been
+ removed. Gem supplies its own package task now.
+
+There is one small behavioral change:
+
+* Non-file tasks now always report the current time as their time
+ stamp. This is different from the previous behavior where non-file
+ tasks reported current time only if there were no prerequisites, and
+ the max prerequisite timestamp otherwise. This lead to inconsistent
+ and surprising behavior when adding prerequisites to tasks that in
+ turn were prequisites to file tasks. The new behavior is more
+ consistent and predictable.
+
+==== Changes (from 0.9.3)
+
+Since Rake 10 includes the changes from the last version of Rake 9,
+we'll repeat the changes for version 0.9.3 here.
+
+===== New Features
+
+* Multitask tasks now use a thread pool. Use -j to limit the number of
+ available threads.
+
+* Use -m to turn regular tasks into multitasks (use at your own risk).
+
+* You can now do "Rake.add_rakelib 'dir'" in your Rakefile to
+ programatically add rake task libraries.
+
+* You can specific backtrace suppression patterns (see
+ --suppress-backtrace)
+
+* Directory tasks can now take prerequisites and actions
+
+* Use --backtrace to request a full backtrace without the task trace.
+
+* You can say "--backtrace=stdout" and "--trace=stdout" to route trace
+ output to standard output rather than standard error.
+
+* Optional 'phony' target (enable with 'require 'rake/phony'") for
+ special purpose builds.
+
+* Task#clear now clears task comments as well as actions and
+ prerequisites. Task#clear_comment will specifically target comments.
+
+* The --all option will force -T and -D to consider all the tasks,
+ with and without descriptions.
+
+===== Bug Fixes
+
+* Semi-colons in windows rakefile paths now work.
+
+* Improved Control-C support when invoking multiple test suites.
+
+* egrep method now reads files in text mode (better support for
+ Windows)
+
+* Better deprecation line number reporting.
+
+* The -W option now works with all tasks, whether they have a
+ description or not.
+
+* File globs in rake should not be sorted alphabetically, independent
+ of file system and platform.
+
+* Numerous internal improvements.
+
+* Documentation typos and fixes.
+
+
+==== Thanks
+
+As usual, it was input from users that drove a lot of these changes. The
+following people contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== 0.9.6
+
+Rake version 0.9.6 contains a number of fixes mainly for merging
+Rake into the Ruby source tree and fixing tests.
+
+==== Changes
+
+===== Bug Fixes (0.9.6)
+
+* Better trace output when using a multi-threaded Rakefile.
+* Arg parsing is now consistent for tasks and multitasks.
+* Skip exit code test in versions of Ruby that don't support it well.
+
+Changes for better integration with the Ruby source tree:
+
+* Fix version literal for Ruby source tree build.
+* Better loading of libraries for testing in Ruby build.
+* Use the ruby version provided by Ruby's tests.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== 0.9.5
+
+Rake version 0.9.5 contains a number of bug fixes.
+
+==== Changes
+
+===== Bug Fixes (0.9.5)
+
+* --trace and --backtrace no longer swallow following task names.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== 0.9.4
+
+Rake version 0.9.4 contains a number of bug fixes.
+
+==== Changes
+
+===== Bug Fixes (0.9.4)
+
+* Exit status with failing tests is not correctly set to non-zero.
+
+* Simplified syntax for phony task (for older versions of RDoc).
+
+* Stand alone FileList usage gets glob function (without loading in
+ extra dependencies)
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== 0.9.3
+
+Rake version 0.9.3 contains some new, backwards compatible features and
+a number of bug fixes.
+
+==== Changes
+
+===== New Features
+
+* Multitask tasks now use a thread pool. Use -j to limit the number of
+ available threads.
+
+* Use -m to turn regular tasks into multitasks (use at your own risk).
+
+* You can now do "Rake.add_rakelib 'dir'" in your Rakefile to
+ programatically add rake task libraries.
+
+* You can specific backtrace suppression patterns (see
+ --suppress-backtrace)
+
+* Directory tasks can now take prerequisites and actions
+
+* Use --backtrace to request a full backtrace without the task trace.
+
+* You can say "--backtrace=stdout" and "--trace=stdout" to route trace
+ output to standard output rather than standard error.
+
+* Optional 'phony' target (enable with 'require 'rake/phony'") for
+ special purpose builds.
+
+* Task#clear now clears task comments as well as actions and
+ prerequisites. Task#clear_comment will specifically target comments.
+
+* The --all option will force -T and -D to consider all the tasks,
+ with and without descriptions.
+
+===== Bug Fixes
+
+* Semi-colons in windows rakefile paths now work.
+
+* Improved Control-C support when invoking multiple test suites.
+
+* egrep method now reads files in text mode (better support for
+ Windows)
+
+* Better deprecation line number reporting.
+
+* The -W option now works with all tasks, whether they have a
+ description or not.
+
+* File globs in rake should not be sorted alphabetically, independent
+ of file system and platform.
+
+* Numerous internal improvements.
+
+* Documentation typos and fixes.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Aaron Patterson
+* Dylan Smith
+* Jo Liss
+* Jonas Pfenniger
+* Kazuki Tsujimoto
+* Michael Bishop
+* Michael Elufimov
+* NAKAMURA Usaku
+* Ryan Davis
+* Sam Grönblom
+* Sam Phippen
+* Sergio Wong
+* Tay Ray Chuan
+* grosser
+* quix
+
+Also, many thanks to Eric Hodel for assisting with getting this release
+out the door.
+
+-- Jim Weirich
+
+=== Rake 0.9.2.2
+
+Rake version 0.9.2.2 is mainly bug fixes.
+
+==== Changes
+
+* The rake test loader now removes arguments it has processed. Issue #51
+* Rake::TaskArguments now responds to #values\_at
+* RakeFileUtils.verbose_flag = nil silences output the same as 0.8.7
+* Rake tests are now directory-independent
+* Rake tests are no longer require flexmock
+* Commands constant is no longer polluting top level namespace.
+* Show only the interesting portion of the backtrace by default (James M. Lawrence).
+* Added --reduce-compat option to remove backward compatible DSL hacks (James M. Lawrence).
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* James M. Lawrence (quix)
+* Roger Pack
+* Cezary Baginski
+* Sean Scot August Moon
+* R.T. Lechow
+* Alex Chaffee
+* James Tucker
+* Matthias Lüdtke
+* Santiago Pastorino
+
+Also, bit thanks to Eric Hodel for assisting with getting this release
+out the door (where "assisting" includes, but is not by any means
+limited to, "pushing" me to get it done).
+
+-- Jim Weirich
+
+=== 0.9.2
+
+Rake version 0.9.2 has a few small fixes. See below for details.
+
+==== Changes
+
+* Support for Ruby 1.8.6 was fixed.
+* Global DSL warnings now honor --no-deprecate
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* James M. Lawrence (quix)
+* Roger Pack
+* Cezary Baginski
+* Sean Scot August Moon
+* R.T. Lechow
+* Alex Chaffee
+* James Tucker
+* Matthias Lüdtke
+* Santiago Pastorino
+
+Also, bit thanks to Eric Hodel for assisting with getting this release
+out the door (where "assisting" includes, but is not by any means
+limited to, "pushing" me to get it done).
+
+-- Jim Weirich
+
+=== 0.9.1
+
+Rake version 0.9.1 has a number of bug fixes and enhancments (see
+below for more details). Additionally, the internals have be slightly
+restructured and improved.
+
+==== Changes
+
+Rake 0.9.1 adds back the global DSL methods, but with deprecation
+messages. This allows Rake 0.9.1 to be used with older rakefiles with
+warning messages.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* James M. Lawrence (quix)
+* Roger Pack
+* Cezary Baginski
+* Sean Scot August Moon
+* R.T. Lechow
+* Alex Chaffee
+* James Tucker
+* Matthias Lüdtke
+* Santiago Pastorino
+
+Also, bit thanks to Eric Hodel for assisting with getting this release
+out the door (where "assisting" includes, but is not by any means
+limited to, "pushing" me to get it done).
+
+-- Jim Weirich
+
+=== 0.9.0
+
+Rake version 0.9.0 has a number of bug fixes and enhancments (see
+below for more details). Additionally, the internals have be slightly
+restructured and improved.
+
+==== Changes
+
+===== New Features / Enhancements / Bug Fixes in Version 0.9.0
+
+* Rake now warns when the deprecated :needs syntax used (and suggests
+ the proper syntax in the warning).
+
+* Moved Rake DSL commands to top level ruby object 'main'. Rake DSL
+ commands are no longer private methods in Object. (Suggested by
+ James M. Lawrence/quix)
+
+* Rake now uses case-insensitive comparisons to find the Rakefile on Windows.
+ Based on patch by Roger Pack.
+
+* Rake now requires (instead of loads) files in the test task. Patch by Cezary
+ Baginski.
+
+* Fixed typos. Patches by Sean Scot August Moon and R.T. Lechow.
+
+* Rake now prints the Rakefile directory only when it's different from the
+ current directory. Patch by Alex Chaffee.
+
+* Improved rakefile_location discovery on Windows. Patch by James Tucker.
+
+* Rake now recognizes "Windows Server" as a windows system. Patch by Matthias
+ Lüdtke
+
+* Rake::RDocTask is deprecated. Use RDoc::Task from RDoc 2.4.2+ (require
+ 'rdoc/task')
+
+* Rake::GemPackageTask is deprecated. Use Gem::PackageTask (require
+ 'rubygems/package\_task')
+
+* Rake now outputs various messages to $stderr instead of $stdout.
+
+* Rake no longer emits warnings for Config. Patch by Santiago Pastorino.
+
+* Removed Rake's DSL methods from the top level scope. If you need to
+ call 'task :xzy' in your code, include Rake::DSL into your class, or
+ put the code in a Rake::DSL.environment do ... end block.
+
+* Split rake.rb into individual files.
+
+* Support for the --where (-W) flag for showing where a task is defined.
+
+* Fixed quoting in test task.
+ (http://onestepback.org/redmine/issues/show/44,
+ http://www.pivotaltracker.com/story/show/1223138)
+
+* Fixed the silent option parsing problem.
+ (http://onestepback.org/redmine/issues/show/47)
+
+* Fixed :verbose=>false flag on sh and ruby commands.
+
+* Rake command line options may be given by default in a RAKEOPT
+ environment variable.
+
+* Errors in Rake will now display the task invocation chain in effect
+ at the time of the error.
+
+* Accepted change by warnickr to not expand test patterns in shell
+ (allowing more files in the test suite).
+
+* Fixed that file tasks did not perform prereq lookups in scope
+ (Redmine #57).
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* James M. Lawrence (quix)
+* Roger Pack
+* Cezary Baginski
+* Sean Scot August Moon
+* R.T. Lechow
+* Alex Chaffee
+* James Tucker
+* Matthias Lüdtke
+* Santiago Pastorino
+
+Also, bit thanks to Eric Hodel for assisting with getting this release
+out the door (where "assisting" includes, but is not by any means
+limited to, "pushing" me to get it done).
+
+-- Jim Weirich
+
+
+=== 0.8.7
+
+Rake version 0.8.5 introduced greatly improved support for executing
+commands on Windows. The "sh" command now has the same semantics on
+Windows that it has on Unix based platforms.
+
+Rake version 0.8.6 includes minor fixes the the RDoc generation.
+Rake version 0.8.7 includes a minor fix for JRuby running on windows.
+
+==== Changes
+
+===== New Features / Enhancements in Version 0.8.5
+
+* Improved implementation of the Rake system command for Windows.
+ (patch from James M. Lawrence/quix)
+
+* Support for Ruby 1.9's improved system command. (patch from James
+ M. Lawrence/quix)
+
+* Rake now includes the configured extension when invoking an
+ executable (Config::CONFIG['EXEEXT])
+
+===== Bug Fixes in Version 0.8.5
+
+* Environment variable keys are now correctly cased (it matters in
+ some implementations).
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Charles Nutter
+
+-- Jim Weirich
+
+=== 0.8.6
+
+Rake version 0.8.5 introduced greatly improved support for executing
+commands on Windows. The "sh" command now has the same semantics on
+Windows that it has on Unix based platforms.
+
+Rake version 0.8.5 includes minor fixes the the RDoc generation.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* James M. Lawrence/quix
+* Luis Lavena
+
+-- Jim Weirich
+
+=== 0.8.5
+
+Rake version 0.8.5 is a new release of Rake with greatly improved
+support for executing commands on Windows. The "sh" command now has
+the same semantics on Windows that it has on Unix based platforms.
+
+==== Changes
+
+===== New Features / Enhancements in Version 0.8.5
+
+* Improved implementation of the Rake system command for Windows.
+ (patch from James M. Lawrence/quix)
+
+* Support for Ruby 1.9's improved system command. (patch from James
+ M. Lawrence/quix)
+
+* Rake now includes the configured extension when invoking an
+ executable (Config::CONFIG['EXEEXT])
+
+===== Bug Fixes in Version 0.8.5
+
+* Environment variable keys are now correctly cased (it matters in
+ some implementations).
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* James M. Lawrence/quix
+* Luis Lavena
+
+-- Jim Weirich
+
+=== 0.8.4
+
+Rake version 0.8.4 is a bug-fix release of rake.
+
+NOTE: The version of Rake that comes with Ruby 1.9 has diverged
+ slightly from the core Rake code base. Rake 0.8.4 will work
+ with Ruby 1.9, but is not a strict upgrade for the Rake that
+ comes with Ruby 1.9. A (near) future release of Rake will unify
+ those two codebases.
+
+==== Letter Writing Campaign
+
+Thanks to Aaron Patterson (@tenderlove) and Eric Hodel (@drbrain) for
+their encouraging support in organizing a letter writing campaign to
+lobby for the "Warning Free" release of rake 0.8.4. A special callout
+goes to Jonathan D. Lord, Sr (Dr. Wingnut) whose postcard was the
+first to actually reach me. (see
+http://tenderlovemaking.com/2009/02/26/we-need-a-new-version-of-rake/
+for details)
+
+==== Changes
+
+===== New Features / Enhancements in Version 0.8.4
+
+* Case is preserved on rakefile names. (patch from James
+ M. Lawrence/quix)
+
+* Improved Rakefile case insensitivity testing (patch from Luis
+ Lavena).
+
+* Windows system dir search order is now: HOME, HOMEDRIVE + HOMEPATH,
+ APPDATA, USERPROFILE (patch from Luis Lavena)
+
+* MingGW is now recognized as a windows platform. (patch from Luis
+ Lavena)
+
+===== Bug Fixes in Version 0.8.4
+
+* Removed reference to manage_gem to fix the warning produced by the
+ gem package task.
+
+* Fixed stray ARGV option problem that was interfering with
+ Test::Unit::Runner. (patch from Pivotal Labs)
+
+===== Infrastructure Improvements in Version 0.8.4
+
+* Numerous fixes to the windows test suite (patch from Luis Lavena).
+
+* Improved Rakefile case insensitivity testing (patch from Luis
+ Lavena).
+
+* Better support for windows paths in the test task (patch from Simon
+ Chiang/bahuvrihi)
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* James M. Lawrence/quix
+* Luis Lavena
+* Pivotal Labs
+* Simon Chiang/bahuvrihi
+
+-- Jim Weirich
+
+=== 0.8.3
+
+Rake version 0.8.3 is a bug-fix release of rake.
+
+==== Changes
+
+===== Bug Fixes in Version 0.8.3
+
+* Enhanced the system directory detection in windows. We now check
+ HOMEDRIVE/HOMEPATH and USERPROFILE if APPDATA isn't found. (Patch
+ supplied by James Tucker). Rake no long aborts if it can't find the
+ directory.
+
+* Added fix to handle ruby installations in directories with spaces in
+ their name.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Edwin Pratomo
+* Gavin Stark
+* Adam Q. Salter
+* Adam Majer
+* Emanuel Indermühle
+* Ittay Dror
+* Bheeshmar Redheendran (for spending an afternoon with me debugging
+ windows issues)
+
+-- Jim Weirich
+
+
+=== 0.8.2
+
+Rake version 0.8.2 is a new release of rake that includes a number of
+new features and numerous bug fixes.
+
+==== Changes
+
+===== New Features in Version 0.8.2
+
+* Switched from getoptlong to optparse (patches supplied by Edwin
+ Pratomo).
+
+* The -T option will now attempt to dynamically sense the size of the
+ terminal. The -T output will only self-truncate if the output is a
+ tty. However, if RAKE_COLUMNS is explicitly set, it will be honored
+ in any case. (Patch provided by Gavin Stark).
+
+* The following public methods have been added to rake task objects:
+
+ * task.clear -- Clear both the prerequisites and actions of the
+ target rake task.
+ * task.clear_prerequisites -- Clear all the existing prerequisites
+ from the target rake task.
+ * task.clear_actions -- Clear all the existing actions from the
+ target rake task.
+ * task.reenable -- Re-enable a task, allowing its actions to be
+ executed again if the task is invoked.
+
+* Changed RDoc test task to have no default template. This makes it
+ easier for the tempate to pick up the template from the environment.
+
+* Default values for task arguments can easily be specified with the
+ :with_defaults method. (Idea for default argument merging supplied
+ by (Adam Q. Salter)
+
+===== Bug Fixes in Version 0.8.2
+
+* Fixed bug in package task so that it will include the subdir
+ directory in the package for testing. (Bug found by Adam Majer)
+
+* Fixed filename dependency order bug in test\_inspect\_pending and
+ test\_to\_s\_pending. (Bug found by Adam Majer)
+
+* Fixed check for file utils options to make them immune to the
+ symbol/string differences. (Patch supplied by Edwin Pratomo)
+
+* Fixed bug with rules involving multiple source, where only the first
+ dependency of a rule has any effect (Patch supplied by Emanuel
+ Indermühle)
+
+* FileList#clone and FileList#dup have better sematics w.r.t. taint
+ and freeze.
+
+* Changed from using Mutex to Monitor. Evidently Mutex causes thread
+ join errors when Ruby is compiled with -disable-pthreads. (Patch
+ supplied by Ittay Dror)
+
+* Fixed bug in makefile parser that had problems with extra spaces in
+ file task names. (Patch supplied by Ittay Dror)
+
+==== Other changes in Version 0.8.2
+
+* Added ENV var to rake's own Rakefile to prevent OS X from including
+ extended attribute junk in the rake package tar file. (Bug found by
+ Adam Majer)
+
+* Added a performance patch for reading large makefile dependency
+ files. (Patch supplied by Ittay Dror)
+
+==== Task Argument Examples
+
+Prior to version 0.8.0, rake was only able to handle command line
+arguments of the form NAME=VALUE that were passed into Rake via the
+ENV hash. Many folks had asked for some kind of simple command line
+arguments, perhaps using "--" to separate regular task names from
+argument values on the command line. The problem is that there was no
+easy way to associate positional arguments on the command line with
+different tasks. Suppose both tasks :a and :b expect a command line
+argument: does the first value go with :a? What if :b is run first?
+Should it then get the first command line argument.
+
+Rake 0.8.0 solves this problem by explicitly passing values directly
+to the tasks that need them. For example, if I had a release task
+that required a version number, I could say:
+
+ rake release[0.8.2]
+
+And the string "0.8.2" will be passed to the :release task. Multiple
+arguments can be passed by separating them with a comma, for example:
+
+ rake name[john,doe]
+
+Just a few words of caution. The rake task name and its arguments
+need to be a single command line argument to rake. This generally
+means no spaces. If spaces are needed, then the entire rake +
+argument string should be quoted. Something like this:
+
+ rake "name[billy bob, smith]"
+
+(Quoting rules vary between operating systems and shells, so make sure
+you consult the proper docs for your OS/shell).
+
+===== Tasks that Expect Parameters
+
+Parameters are only given to tasks that are setup to expect them. In
+order to handle named parameters, the task declaration syntax for
+tasks has been extended slightly.
+
+For example, a task that needs a first name and last name might be
+declared as:
+
+ task :name, :first_name, :last_name
+
+The first argument is still the name of the task (:name in this case).
+The next to argumements are the names of the parameters expected by
+:name (:first_name and :last_name in the example).
+
+To access the values of the parameters, the block defining the task
+behaviour can now accept a second parameter:
+
+ task :name, :first_name, :last_name do |t, args|
+ puts "First name is #{args.first_name}"
+ puts "Last name is #{args.last_name}"
+ end
+
+The first argument of the block "t" is always bound to the current
+task object. The second argument "args" is an open-struct like object
+that allows access to the task arguments. Extra command line
+arguments to a task are ignored. Missing command line arguments are
+given the nil value.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Edwin Pratomo
+* Gavin Stark
+* Adam Q. Salter
+* Adam Majer
+* Emanuel Indermühle
+* Ittay Dror
+* Bheeshmar Redheendran (for spending an afternoon with me debugging
+ windows issues)
+
+-- Jim Weirich
+
+=== 0.8.0/0.8.1
+
+Rake version 0.8.0 is a new release of rake that includes serveral new
+features.
+
+==== Changes
+
+===== New Features in Version 0.8.0
+
+* Tasks can now receive command line parameters. See the examples
+ below for more details.
+
+* Comments are limited to 80 columns on output, but full comments can
+ be seen by using the -D parameter. (feature suggested by Jamis
+ Buck).
+
+* Explicit exit(n) calls will now set the exit status to n. (patch
+ provided by Stephen Touset).
+
+* Rake is now compatible with Ruby 1.9.
+
+Version 0.8.1 is a minor update that includes additional Ruby 1.9
+compatibility fixes.
+
+==== Task Argument Examples
+
+Prior to version 0.8.0, rake was only able to handle command line
+arguments of the form NAME=VALUE that were passed into Rake via the
+ENV hash. Many folks had asked for some kind of simple command line
+arguments, perhaps using "--" to separate regular task names from
+argument values on the command line. The problem is that there was no
+easy way to associate positional arguments on the command line with
+different tasks. Suppose both tasks :a and :b expect a command line
+argument: does the first value go with :a? What if :b is run first?
+Should it then get the first command line argument.
+
+Rake 0.8.0 solves this problem by explicitly passing values directly
+to the tasks that need them. For example, if I had a release task
+that required a version number, I could say:
+
+ rake release[0.8.0]
+
+And the string "0.8.0" will be passed to the :release task. Multiple
+arguments can be passed by separating them with a comma, for example:
+
+ rake name[john,doe]
+
+Just a few words of caution. The rake task name and its arguments
+need to be a single command line argument to rake. This generally
+means no spaces. If spaces are needed, then the entire rake +
+argument string should be quoted. Something like this:
+
+ rake "name[billy bob, smith]"
+
+(Quoting rules vary between operating systems and shells, so make sure
+you consult the proper docs for your OS/shell).
+
+===== Tasks that Expect Parameters
+
+Parameters are only given to tasks that are setup to expect them. In
+order to handle named parameters, the task declaration syntax for
+tasks has been extended slightly.
+
+For example, a task that needs a first name and last name might be
+declared as:
+
+ task :name, :first_name, :last_name
+
+The first argument is still the name of the task (:name in this case).
+The next to argumements are the names of the parameters expected by
+:name (:first_name and :last_name in the example).
+
+To access the values of the parameters, the block defining the task
+behaviour can now accept a second parameter:
+
+ task :name, :first_name, :last_name do |t, args|
+ puts "First name is #{args.first_name}"
+ puts "Last name is #{args.last_name}"
+ end
+
+The first argument of the block "t" is always bound to the current
+task object. The second argument "args" is an open-struct like object
+that allows access to the task arguments. Extra command line
+arguments to a task are ignored. Missing command line arguments are
+given the nil value.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+* Jamis Buck (for comment formatting suggestions)
+* Stephen Touset (for exit status patch).
+
+-- Jim Weirich
+
+
+=== 0.7.3
+
+Rake version 0.7.3 is a minor release that includes some refactoring to better
+support custom Rake applications.
+
+==== Changes
+
+===== New Features in Version 0.7.3
+
+* Added the +init+ and +top_level+ methods to make the creation of custom Rake applications a bit easier. E.g.
+
+ gem 'rake', ">= 0.7.3"
+ require 'rake'
+
+ Rake.application.init('myrake')
+
+ task :default do
+ something_interesting
+ end
+
+ Rake.application.top_level
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes. The
+following people either contributed patches, made suggestions or made
+otherwise helpful comments. Thanks to ...
+
+-- Jim Weirich
+
+
+=== 0.7.2
+
+
+Version 0.7.2 supplies a bug fix and a few minor enhancements. In
+particular, the new version fixes an incompatibility with the soon to
+be released Ruby 1.8.6. We strongly recommend upgrading to Rake 0.7.2
+in order to be compatible with the new version of Ruby.
+
+==== Changes
+
+===== Bug Fixes in 0.7.2
+
+There are quite a number of bug fixes in the new 0.7.2 version of
+Rake:
+
+* Removed dependency on internal fu_xxx functions from FileUtils.
+
+* Error messages are now send to stderr rather than stdout (from
+ Payton Quackenbush).
+
+* Better error handling on invalid command line arguments (from Payton
+ Quackenbush).
+
+* Fixed some bugs where the application object was going to the global
+ appliation instead of using its own data.
+
+* Fixed the method name leak from FileUtils (bug found by Glenn
+ Vanderburg).
+
+* Added test for noop, bad_option and verbose flags to sh command.
+
+* Added a description to the gem task in GemPackageTask.
+
+* Fixed a bug when rules have multiple prerequisites (patch by Joel
+ VanderWerf)
+
+* Added the handful of RakeFileUtils to the private method as well.
+
+===== New Features in 0.7.2
+
+The following new features are available in Rake version 0.7.2:
+
+* Added square and curly bracket patterns to FileList#include (Tilman
+ Sauerbeck).
+
+* FileLists can now pass a block to FileList#exclude to exclude files
+ based on calculated values.
+
+* Added plain filename support to rule dependents (suggested by Nobu
+ Nakada).
+
+* Added pathmap support to rule dependents. In other words, if a
+ pathmap format (beginning with a '%') is given as a Rake rule
+ dependent, then the name of the depend will be the name of the
+ target with the pathmap format applied.
+
+* Added a 'tasks' method to a namespace to get a list of tasks
+ associated with the namespace.
+
+* Added tar_command and zip_command options to the Package task.
+
+* The clean task will no longer delete 'core' if it is a directory.
+
+===== Internal Rake Improvements
+
+The following changes will are mainly internal improvements and
+refactorings and have little effect on the end user. But they may be
+of interest to the general public.
+
+* Added rcov task and updated unit testing for better code coverage.
+
+* Added a 'shame' task to the Rakefile.
+
+* Added rake_extension to handle detection of extension collisions.
+
+* Added a protected 'require "rubygems"' to test/test_application to
+ unbreak cruisecontrol.rb.
+
+* Removed rake\_dup. Now we just simply rescue a bad dup.
+
+* Refactored the FileList reject logic to remove duplication.
+
+* Removed if \_\_FILE\_\_ at the end of the rake.rb file.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes.
+The following people either contributed patches, made suggestions or
+made otherwise helpful comments. Thanks to ...
+
+* Payton Quackenbush -- For several error handling improvements.
+
+* Glenn Vanderburg -- For finding and fixing the method name leak from
+ FileUtils.
+
+* Joel VanderWerf -- for finding and fixing a bug in the handling of
+ multiple prerequisites.
+
+* Tilman Sauerbeck -- For some enhancing FileList to support more
+ advanced file globbing.
+
+* Nobu Nakada -- For suggesting plain file name support to rule dependents.
+
+-- Jim Weirich
+
+=== 0.7.1
+
+Version 0.7.1 supplies a bug fix and a few minor enhancements.
+
+==== Changes
+
+===== Bug Fixes in 0.7.1
+
+* Changes in the exception reported for the FileUtils.ln caused
+ safe_ln to fail with a NotImplementedError. Rake 0.7.1 will now
+ catch that error or any StandardError and properly fall back to
+ using +cp+.
+
+===== New Features in 0.7.1
+
+* You can filter the results of the --task option by supplying an
+ optional regular expression. This allows the user to easily find a
+ particular task name in a long list of possible names.
+
+* Transforming procs in a rule may now return a list of prerequisites.
+ This allows more flexible rule formation.
+
+* FileList and String now support a +pathmap+ melthod that makes the
+ transforming paths a bit easier. See the API docs for +pathmap+ for
+ details.
+
+* The -f option without a value will disable the search for a
+ Rakefile. This allows the Rakefile to be defined entirely in a
+ library (and loaded with the -r option). The current working
+ directory is not changed when this is done.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes.
+The following people either contributed patches, made suggestions or
+made otherwise helpful comments. Thanks to ...
+
+* James Britt and Assaph Mehr for reporting and helping to debug the
+ safe_ln issue.
+
+-- Jim Weirich
+
+
+=== 0.7.0
+
+These changes for Rake have been brewing for a long time. Here they
+are, I hope you enjoy them.
+
+==== Changes
+
+===== New Features
+
+* Name space support for task names (see below).
+* Prerequisites can be executed in parallel (see below).
+* Added safe_ln support for openAFS (via Ludvig Omholt).
+* RDoc defaults to internal (in-process) invocation. The old behavior
+ is still available by setting the +external+ flag to true.
+* Rakefiles are now loaded with the expanded path to prevent
+ accidental pollution from the Ruby load path.
+* Task objects my now be used in prerequisite lists directly.
+* Task objects (in addition to task names) may now be included in the
+ prerequisite list of a task.
+* Internals cleanup and refactoring.
+
+===== Bug Fixes
+
+* Compatibility fixes for Ruby 1.8.4 FileUtils changes.
+
+===== Namespaces
+
+Tasks can now be nested inside their own namespaces. Tasks within one
+namespace will not accidentally interfer with tasks named in a different
+namespace.
+
+For example:
+
+ namespace "main" do
+ task :build do
+ # Build the main program
+ end
+ end
+
+ namespace "samples" do
+ task :build do
+ # Build the sample programs
+ end
+ end
+
+ task :build_all => ["main:build", "samples:build"]
+
+Even though both tasks are named :build, they are separate tasks in
+their own namespaces. The :build_all task (defined in the toplevel
+namespace) references both build tasks in its prerequisites.
+
+You may invoke each of the individual build tasks with the following
+commands:
+
+ rake main:build
+ rake samples:build
+
+Or invoke both via the :build_all command:
+
+ rake build_all
+
+Namespaces may be nested arbitrarily. Since the name of file tasks
+correspond to the name of a file in the external file system,
+FileTasks are not affected by the namespaces.
+
+See the Rakefile format documentation (in the Rake API documents) for
+more information.
+
+===== Parallel Tasks
+
+Sometimes you have several tasks that can be executed in parallel. By
+specifying these tasks as prerequisites to a +multitask+ task.
+
+In the following example the tasks copy\_src, copy\_doc and copy\_bin
+will all execute in parallel in their own thread.
+
+ multitask :copy_files => [:copy_src, :copy_doc, :copy_bin] do
+ puts "All Copies Complete"
+ end
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes.
+The following people either contributed patches, made suggestions or
+made otherwise helpful comments. Thanks to ...
+
+* Doug Young (inspiration for the parallel task)
+* David Heinemeier Hansson (for --trace message enhancement and for
+ pushing for namespace support).
+* Ludvig Omholt (for the openAFS fix)
+
+-- Jim Weirich
+
+=== 0.6.1
+
+* Rebuilt 0.6.0 gem without signing.
+
+=== 0.6.0
+
+Its time for some long requested enhancements and lots of bug fixes
+... And a whole new web page.
+
+==== New Web Page
+
+The primary documentation for rake has moved from the RubyForge based
+wiki to its own Hieraki based web site. Constant spam on the wiki
+made it a difficult to keep clean. The new site will be easier to
+update and organize.
+
+Check out the new documentation at: http://docs.rubyrake.org
+
+We will be adding new documentation to the site as time goes on.
+
+In addition to the new docs page, make sure you check out Martin
+Fowlers article on rake at http://martinfowler.com/articles/rake.html
+
+==== Changes
+
+===== New Features
+
+* Multiple prerequisites on Rake rules now allowed. However, keep the
+ following in mind:
+
+ 1. All the prerequisites of a rule must be available before a rule
+ is triggered, where "enabled" means (a) an existing file, (b) a
+ defined rule, or (c) another rule which also must be
+ trigger-able.
+ 2. Rules are checked in order of definition, so it is important to
+ order your rules properly. If a file can be created by two
+ different rules, put the more specific rule first (otherwise the
+ more general rule will trigger first and the specific one will
+ never be triggered).
+ 3. The source method now returns the name of the first
+ prerequisite listed in the rule. sources returns the
+ names of all the rule prerequisites, ordered as they are defined
+ in the rule. If the task has other prerequisites not defined in
+ the rule (but defined in an explicit task definition), then they
+ will _not_ be included in the sources list.
+
+* FileLists may now use the egrep command. This popular enhancement
+ is now a core part of the FileList object. If you want to get a
+ list of all your to-dos, fixmes and TBD comments, add the following
+ to your Rakefile.
+
+ desc "Look for TODO and FIXME tags in the code"
+ task :todo do
+ FileList['**/*.rb'].egrep /#.*(FIXME|TODO|TBD)/
+ end
+
+* The investigation method was added to task object to dump
+ out some important values. This makes it a bit easier to debug Rake
+ tasks.
+
+ For example, if you are having problems with a particular task, just
+ print it out:
+
+ task :huh do
+ puts Rake::Task['huh'].investigation
+ end
+
+* The Rake::TestTask class now supports a "ruby\_opts" option to pass
+ arbitrary ruby options to a test subprocess.
+
+===== Some Incompatibilities
+
+* When using the ruby command to start a Ruby subprocess, the
+ Ruby interpreter that is currently running rake is used by default.
+ This makes it easier to use rake in an environment with multiple
+ ruby installation. (Previously, the first ruby command found in the
+ PATH was used).
+
+ If you wish to chose a different Ruby interpreter, you can
+ explicitly choose the interpreter via the sh command.
+
+* The major rake classes (Task, FileTask, FileCreationTask, RakeApp)
+ have been moved out of the toplevel scope and are now accessible as
+ Rake::Task, Rake::FileTask, Rake::FileCreationTask and
+ Rake::Application. If your Rakefile
+ directly references any one of these tasks, you may:
+
+ 1. Update your Rakefile to use the new classnames
+ 2. Use the --classic-namespace option on the rake command to get the
+ old behavior,
+ 3. Add require 'rake/classic_namespace'
to the
+ Rakefile to get the old behavior.
+
+ rake will print a rather annoying warning whenever a
+ deprecated class name is referenced without enabling classic
+ namespace.
+
+===== Bug Fixes
+
+* Several unit tests and functional tests were fixed to run better
+ under windows.
+
+* Directory tasks are now a specialized version of a File task. A
+ directory task will only be triggered if it doesn't exist. It will
+ not be triggered if it is out of date w.r.t. any of its
+ prerequisites.
+
+* Fixed a bug in the Rake::GemPackageTask class so that the gem now
+ properly contains the platform name.
+
+* Fixed a bug where a prerequisite on a file task would cause
+ an exception if the prerequisite did not exist.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes.
+The following people either contributed patches, made suggestions or
+made otherwise helpful comments. Thanks to ...
+
+* Greg Fast (better ruby_opt test options)
+* Kelly Felkins (requested by better namespace support)
+* Martin Fowler (suggested Task.investigation)
+* Stuart Jansen (send initial patch for multiple prerequisites).
+* Masao Mutch (better support for non-ruby Gem platforms)
+* Philipp Neubeck (patch for file task exception fix)
+
+-- Jim Weirich
+
+=== 0.5.4
+
+Time for some minor bug fixes and small enhancements
+
+==== Changes
+
+Here are the changes for version 0.5.4 ...
+
+* Added double quotes to the test runner. This allows the location of
+ the tests (and runner) to be in a directory path that contains
+ spaces (e.g. "C:/Program Files/ruby/bin").
+* Added .svn to default ignore list. Now subversion project metadata
+ is automatically ignored by Rake's FileList.
+* Updated FileList#include to support nested arrays and filelists.
+ FileLists are flat lists of file names. Using a FileList in an
+ include will flatten out the nested file names.
+
+== Thanks
+
+As usual, it was input from users that drove a alot of these changes.
+Thanks to ...
+
+* Tilman Sauerbeck for the nested FileList suggestion.
+* Josh Knowles for pointing out the spaces in directory name problem.
+
+-- Jim Weirich
+
+=== 0.5.3
+
+Although it has only been two weeks since the last release, we have
+enough updates to the Rake program to make it time for another
+release.
+
+==== Changes
+
+Here are the changes for version 0.5.3 ...
+
+* FileLists have been extensively changed so that they mimic the
+ behavior of real arrays even more closely. In particular,
+ operations on FileLists that return a new collection (e.g. collect,
+ reject) will now return a FileList rather than an array. In
+ addition, several places where FileLists were not properly expanded
+ before use have been fixed.
+* A method (+ext+) to simplify the handling of file extensions was
+ added to String and to Array.
+* The 'testrb' script in test/unit tends to silently swallow syntax
+ errors in test suites. Because of that, the default test loader is
+ now a rake-provided script. You can still use 'testrb' by setting
+ the loader flag in the test task to :testrb. (See the API documents
+ for TestTask for all the loader flag values).
+* FileUtil methods (e.g. cp, mv, install) are now declared to be
+ private. This will cut down on the interference with user defined
+ methods of the same name.
+* Fixed the verbose flag in the TestTask so that the test code is
+ controlled by the flag. Also shortened up some failure messages.
+ (Thanks to Tobias Luetke for the suggestion).
+* Rules will now properly detect a task that can generate a source
+ file. Previously rules would only consider source files that were
+ already present.
+* Added an +import+ command that allows Rake to dynamically import
+ dependendencies into a running Rake session. The +import+ command
+ can run tasks to update the dependency file before loading them.
+ Dependency files can be in rake or make format, allowing rake to
+ work with tools designed to generate dependencies for make.
+
+==== Thanks
+
+As usual, it was input from users that drove a alot of these changes.
+Thanks to ...
+
+* Brian Gernhardt for the rules fix (especially for the patience to
+ explain the problem to me until I got what he was talking about).
+* Stefan Lang for pointing out problems in the dark corners of the
+ FileList implementation.
+* Alexey Verkhovsky pointing out the silently swallows syntax errors
+ in tests.
+* Tobias Luetke for beautifying the test task output.
+* Sam Roberts for some of the ideas behind dependency loading.
+
+-- Jim Weirich
+
+
+=== 0.5.0
+
+It has been a long time in coming, but we finally have a new version
+of Rake available.
+
+==== Changes
+
+* Fixed documentation that was lacking the Rake module name (Tilman
+ Sauerbeck).
+* Added tar.gz and tar.bz2 support to package task (Tilman Sauerbeck).
+* Recursive rules are now supported (Tilman Sauerbeck).
+* Added warning option for the Test Task (requested by Eric Hodel).
+* The jamis rdoc template is only used if it exists.
+* Added fix for Ruby 1.8.2 test/unit and rails problem.
+* Added contributed rake man file (Jani Monoses).
+* Added Brian Candler's fix for problems in --trace and --dry-run
+ mode.
+
+==== Thanks
+
+Lots of people provided input to this release. Thanks to Tilman
+Sauerbeck for numerous patches, documentation fixes and suggestions.
+And for also pushing me to get this release out. Also, thanks to
+Brian Candler for the finding and fixing --trace/dry-run fix. That
+was an obscure bug. Also to Eric Hodel for some good suggestions.
+
+-- Jim Weirich
+
+=== 0.4.15
+
+==== Changes
+
+Version 0.4.15 is a bug fix update for the Ruby 1.8.2 compatibility
+changes. This release includes:
+
+* Fixed a bug that prevented the TESTOPTS flag from working with the
+ revised for 1.8.2 test task.
+* Updated the docs on --trace to indicate that it also enables a full
+ backtrace on errors.
+* Several fixes for new warnings generated.
+
+==== Mini-Roadmap
+
+I will continue to issue Rake updates in the 0.4.xx series as new
+Ruby-1.8.2 issues become manifest. Once the codebase stabilizes, I
+will release a 0.5.0 version incorporating all the changes. If you
+are not using Ruby-1.8.2 and wish to avoid version churn, I recommend
+staying with a release prior to Rake-0.4.14.
+
+=== 0.4.14
+
+Version 0.4.14 is a compatibility fix to allow Rake's test task to
+work under Ruby 1.8.2. A change in the Test::Unit autorun feature
+prevented Rake from running any tests. This release fixes the
+problem.
+
+Rake 0.4.14 is the recommended release for anyone using Ruby 1.8.2.
+
+=== 0.4.13
+
+* Fixed the dry-run flag so it is operating again.
+* Multiple arguments to sh and ruby commands will not be interpreted
+ by the shell (patch provided by Jonathan Paisley).
+
+=== 0.4.12
+
+* Added --silent (-s) to suppress the (in directory) rake message.
+
+=== 0.4.11
+
+* Changed the "don't know how to rake" message (finally)
+* Changes references to a literal "Rakefile" to reference the global
+ variable $rakefile (which contains the actual name of the rakefile).
+
+=== 0.4.10
+
+* Added block support to the "sh" command, allowing users to take
+ special actions on the result of the system call. E.g.
+
+ sh "shell_command" do |ok, res|
+ puts "Program returned #{res.exitstatus}" if ! ok
+ end
+
+=== 0.4.9
+
+* Switched to Jamis Buck's RDoc template.
+* Removed autorequire from Rake's gem spec. This prevents the Rake
+ libraries from loading while using rails.
+
+=== 0.4.8
+
+* Added support for .rb versions of Rakefile.
+* Removed \\\n's from test task.
+* Fixed Ruby 1.9 compatibility issue with FileList.
+
+=== 0.4.7
+
+* Fixed problem in FileList that caused Ruby 1.9 to go into infinite
+ recursion. Since to_a was removed from Object, it does not need to
+ added back into the list of methods to rewrite in FileList. (Thanks
+ to Kent Sibilev for pointing this out).
+
+=== 0.4.6
+* Removed test version of ln in FileUtils that prevented safe_ln from
+ using ln.
+
+=== 0.4.5
+* Upgraded comments in TestTask.
+* FileList to_s and inspect now automatically resolve pending changes.
+* FileList#exclude properly returns the FileList.
+
+=== 0.4.4
+* Fixed initialization problem with @comment.
+* Now using multi -r technique in TestTask. Switch Rakefile back to
+ using the built-in test task macros because the rake runtime is no
+ longer needed.
+* Added 'TEST=filename' and 'TESTOPTS=options' to the Test Task
+ macros.
+* Allow a +test_files+ attribute in test tasks. This allows more
+ flexibility in specifying test files.
+
+=== 0.4.3
+* Fixed Comment leakage.
+
+=== 0.4.2
+* Added safe_ln that falls back to a copy if a file link is not supported.
+* Package builder now uses safe\_ln.
+
+=== 0.4.1
+* Task comments are now additive, combined with "/".
+* Works with (soon to be released) rubygems 0.6.2 (or 0.7.0)
+
+=== 0.4.0
+* FileList now uses deferred loading. The file system is not searched
+ until the first call that needs the file names.
+* VAR=VALUE options are now accepted on the command line and are
+ treated like environment variables. The values may be tested in a
+ Rakefile by referencing ENV['VAR'].
+* File.mtime is now used (instead of File.new().mtime).
+
+=== 0.3.2.x
+
+* Removed some hidden dependencies on rubygems. Tests now will test
+ gems only if they are installed.
+* Removed Sys from some example files. I believe that is that last
+ reference to Sys outside of the contrib area.
+* Updated all copyright notices to include 2004.
+
+=== 0.3.2
+
+* GEM Installation now works with the application stub.
+
+=== 0.3.1
+
+* FileLists now automatically ignore CVS, .bak, !
+* GEM Installation now works.
+
+=== 0.3.0
+
+Promoted 0.2.10.
+
+=== 0.2.10
+General
+
+* Added title to Rake's rdocs
+* Contrib packages are no longer included in the documentation.
+
+RDoc Issues
+
+* Removed default for the '--main' option
+* Fixed rendering of the rdoc options
+* Fixed clean/clobber confusion with rerdoc
+* 'title' attribute added
+
+Package Task Library Issues
+
+* Version (or explicit :noversion) is required.
+* +package_file+ attribute is now writable
+
+FileList Issues
+
+* Dropped bang version of exclude. Now using ant-like include/exclude semantics.
+* Enabled the "yield self" idiom in FileList#initialize.
+
+=== 0.2.9
+
+This version contains numerous changes as the RubyConf.new(2003)
+presentation was being prepared. The changes include:
+
+* The monolithic rubyapp task library is in the process of being
+ dropped in favor of lighter weight task libraries.
+
+=== 0.2.7
+
+* Added "desc" for task descriptions.
+* -T will now display tasks with descriptions.
+* -P will display tasks and prerequisites.
+* Dropped the Sys module in favor of the 1.8.x FileUtils module. Sys
+ is still supported in the contrib area.
+
+=== 0.2.6
+
+* Moved to RubyForge
+
+=== 0.2.5
+
+* Switched to standard ruby app builder.
+* Added no_match option to file matcher.
+
+=== 0.2.4
+
+* Fixed indir, which neglected to actually change directories.
+
+=== 0.2.3
+
+* Added rake module for a help target
+* Added 'for\_files' to Sys
+* Added a $rakefile constant
+* Added test for selecting proper rule with multiple targets.
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/MIT-LICENSE b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/MIT-LICENSE
new file mode 100644
index 00000000..4292f3b3
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/MIT-LICENSE
@@ -0,0 +1,21 @@
+Copyright (c) Jim Weirich
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/README.rdoc b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/README.rdoc
new file mode 100644
index 00000000..5449303a
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/README.rdoc
@@ -0,0 +1,156 @@
+= RAKE -- Ruby Make
+
+home :: https://github.com/ruby/rake
+bugs :: https://github.com/ruby/rake/issues
+docs :: https://ruby.github.io/rake
+build status :: {
}[https://travis-ci.org/ruby/rake] {
}[https://ci.appveyor.com/project/ruby/rake]
+
+== Description
+
+Rake is a Make-like program implemented in Ruby. Tasks and dependencies are
+specified in standard Ruby syntax.
+
+Rake has the following features:
+
+* Rakefiles (rake's version of Makefiles) are completely defined in
+ standard Ruby syntax. No XML files to edit. No quirky Makefile
+ syntax to worry about (is that a tab or a space?)
+
+* Users can specify tasks with prerequisites.
+
+* Rake supports rule patterns to synthesize implicit tasks.
+
+* Flexible FileLists that act like arrays but know about manipulating
+ file names and paths.
+
+* A library of prepackaged tasks to make building rakefiles easier. For example,
+ tasks for building tarballs. (Formerly
+ tasks for building RDoc, Gems, and publishing to FTP were included in rake but they're now
+ available in RDoc, RubyGems, and rake-contrib respectively.)
+
+* Supports parallel execution of tasks.
+
+== Installation
+
+=== Gem Installation
+
+Download and install rake with the following.
+
+ gem install rake
+
+== Usage
+
+=== Simple Example
+
+First, you must write a "Rakefile" file which contains the build rules. Here's
+a simple example:
+
+ task default: %w[test]
+
+ task :test do
+ ruby "test/unittest.rb"
+ end
+
+This Rakefile has two tasks:
+
+* A task named "test", which -- upon invocation -- will run a unit test file
+ in Ruby.
+* A task named "default". This task does nothing by itself, but it has exactly
+ one dependency, namely the "test" task. Invoking the "default" task will
+ cause Rake to invoke the "test" task as well.
+
+Running the "rake" command without any options will cause it to run the
+"default" task in the Rakefile:
+
+ % ls
+ Rakefile test/
+ % rake
+ (in /home/some_user/Projects/rake)
+ ruby test/unittest.rb
+ ....unit test output here...
+
+Type "rake --help" for all available options.
+
+== Resources
+
+=== Rake Information
+
+* {Rake command-line}[rdoc-ref:doc/command_line_usage.rdoc]
+* {Writing Rakefiles}[rdoc-ref:doc/rakefile.rdoc]
+* The original {Rake announcement}[rdoc-ref:doc/rational.rdoc]
+* Rake {glossary}[rdoc-ref:doc/glossary.rdoc]
+
+=== Presentations and Articles about Rake
+
+* Avdi Grimm's rake series:
+ 1. {Rake Basics}[http://devblog.avdi.org/2014/04/21/rake-part-1-basics/]
+ 2. {Rake File Lists}[http://devblog.avdi.org/2014/04/22/rake-part-2-file-lists/]
+ 3. {Rake Rules}[http://devblog.avdi.org/2014/04/23/rake-part-3-rules/]
+ 4. {Rake Pathmap}[http://devblog.avdi.org/2014/04/24/rake-part-4-pathmap/]
+ 5. {File Operations}[http://devblog.avdi.org/2014/04/25/rake-part-5-file-operations/]
+ 6. {Clean and Clobber}[http://devblog.avdi.org/2014/04/28/rake-part-6-clean-and-clobber/]
+ 7. {MultiTask}[http://devblog.avdi.org/2014/04/29/rake-part-7-multitask/]
+* {Jim Weirich's 2003 RubyConf presentation}[http://web.archive.org/web/20140221123354/http://onestepback.org/articles/buildingwithrake/]
+* Martin Fowler's article on Rake: http://martinfowler.com/articles/rake.html
+
+== Other Make Re-envisionings ...
+
+Rake is a late entry in the make replacement field. Here are links to
+other projects with similar (and not so similar) goals.
+
+* http://directory.fsf.org/wiki/Bras -- Bras, one of earliest
+ implementations of "make in a scripting language".
+* http://www.a-a-p.org -- Make in Python
+* http://ant.apache.org -- The Ant project
+* http://search.cpan.org/search?query=PerlBuildSystem -- The Perl Build System
+* http://www.rubydoc.info/gems/rant/0.5.7/frames -- Rant, another Ruby make tool.
+
+== Credits
+
+[Jim Weirich] Who originally created Rake.
+
+[Ryan Dlugosz] For the initial conversation that sparked Rake.
+
+[Nobuyoshi Nakada ] For the initial patch for rule support.
+
+[Tilman Sauerbeck ] For the recursive rule patch.
+
+[Eric Hodel] For aid in maintaining rake.
+
+[Hiroshi SHIBATA] Maintainer of Rake 10.X and Rake 11.X
+
+== License
+
+Rake is available under an MIT-style license.
+
+:include: MIT-LICENSE
+
+---
+
+= Other stuff
+
+Author:: Jim Weirich
+Requires:: Ruby 2.0.0 or later
+License:: Copyright Jim Weirich.
+ Released under an MIT-style license. See the MIT-LICENSE
+ file included in the distribution.
+
+== Warranty
+
+This software is provided "as is" and without any express or implied
+warranties, including, without limitation, the implied warranties of
+merchantability and fitness for a particular purpose.
+
+== Historical
+
+Rake was originally created by Jim Weirich, who unfortunately passed away in
+February 2014. This repository was originally hosted at
+{github.com/jimweirich/rake}[https://github.com/jimweirich/rake/], however
+with his passing, has been moved to {ruby/rake}[https://github.com/ruby/rake].
+
+You can view Jim's last commit here:
+https://github.com/jimweirich/rake/tree/336559f28f55bce418e2ebcc0a57548dcbac4025
+
+You can {read more about Jim}[https://en.wikipedia.org/wiki/Jim_Weirich] at Wikipedia.
+
+Thank you for this great tool, Jim. We'll remember you.
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/Rakefile b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/Rakefile
new file mode 100644
index 00000000..e03dc6fe
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/Rakefile
@@ -0,0 +1,41 @@
+# Rakefile for rake -*- ruby -*-
+
+# Copyright 2003, 2004, 2005 by Jim Weirich (jim@weirichhouse.org)
+# All rights reserved.
+
+# This file may be distributed under an MIT style license. See
+# MIT-LICENSE for details.
+
+lib = File.expand_path("../lib", __FILE__)
+$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
+
+begin
+ require "bundler/gem_tasks"
+rescue LoadError
+end
+
+require "rake/testtask"
+Rake::TestTask.new(:test) do |t|
+ t.libs << "test"
+ t.verbose = true
+ t.test_files = FileList["test/**/test_*.rb"]
+end
+
+require "rdoc/task"
+RDoc::Task.new do |doc|
+ doc.main = "README.rdoc"
+ doc.title = "Rake -- Ruby Make"
+ doc.rdoc_files = FileList.new %w[lib MIT-LICENSE doc/**/*.rdoc *.rdoc]
+ doc.rdoc_dir = "html"
+end
+
+task ghpages: :rdoc do
+ %x[git checkout gh-pages]
+ require "fileutils"
+ FileUtils.rm_rf "/tmp/html"
+ FileUtils.mv "html", "/tmp"
+ FileUtils.rm_rf "*"
+ FileUtils.cp_r Dir.glob("/tmp/html/*"), "."
+end
+
+task default: :test
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/bin/console b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/bin/console
new file mode 100755
index 00000000..b8342352
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/bin/console
@@ -0,0 +1,7 @@
+#!/usr/bin/env ruby
+
+require "bundler/setup"
+require "rake"
+
+require "irb"
+IRB.start
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/bin/setup b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/bin/setup
new file mode 100755
index 00000000..cf4ad25e
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/bin/setup
@@ -0,0 +1,6 @@
+#!/usr/bin/env bash
+set -euo pipefail
+IFS=$'\n\t'
+set -vx
+
+bundle install
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/exe/rake b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/exe/rake
new file mode 100755
index 00000000..a00975f3
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/exe/rake
@@ -0,0 +1,27 @@
+#!/usr/bin/env ruby
+
+#--
+# Copyright (c) 2003, 2004, 2005, 2006, 2007 Jim Weirich
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to
+# deal in the Software without restriction, including without limitation the
+# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
+# sell copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice shall be included in
+# all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+# IN THE SOFTWARE.
+#++
+
+require "rake"
+
+Rake.application.run
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake.rb
new file mode 100644
index 00000000..0dfd0531
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake.rb
@@ -0,0 +1,71 @@
+# frozen_string_literal: true
+#--
+# Copyright 2003-2010 by Jim Weirich (jim.weirich@gmail.com)
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to
+# deal in the Software without restriction, including without limitation the
+# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
+# sell copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice shall be included in
+# all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+# IN THE SOFTWARE.
+#++
+
+module Rake; end
+
+require "rake/version"
+
+require "rbconfig"
+require "fileutils"
+require "singleton"
+require "monitor"
+require "optparse"
+require "ostruct"
+
+require "rake/ext/string"
+
+require "rake/win32"
+
+require "rake/linked_list"
+require "rake/cpu_counter"
+require "rake/scope"
+require "rake/task_argument_error"
+require "rake/rule_recursion_overflow_error"
+require "rake/rake_module"
+require "rake/trace_output"
+require "rake/pseudo_status"
+require "rake/task_arguments"
+require "rake/invocation_chain"
+require "rake/task"
+require "rake/file_task"
+require "rake/file_creation_task"
+require "rake/multi_task"
+require "rake/dsl_definition"
+require "rake/file_utils_ext"
+require "rake/file_list"
+require "rake/default_loader"
+require "rake/early_time"
+require "rake/late_time"
+require "rake/name_space"
+require "rake/task_manager"
+require "rake/application"
+require "rake/backtrace"
+
+$trace = false
+
+# :stopdoc:
+#
+# Some top level Constants.
+
+FileList = Rake::FileList
+RakeFileUtils = Rake::FileUtilsExt
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/application.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/application.rb
new file mode 100644
index 00000000..c86cb1fa
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/application.rb
@@ -0,0 +1,824 @@
+# frozen_string_literal: true
+require "optparse"
+
+require "rake/task_manager"
+require "rake/file_list"
+require "rake/thread_pool"
+require "rake/thread_history_display"
+require "rake/trace_output"
+require "rake/win32"
+
+module Rake
+
+ CommandLineOptionError = Class.new(StandardError)
+
+ ##
+ # Rake main application object. When invoking +rake+ from the
+ # command line, a Rake::Application object is created and run.
+
+ class Application
+ include TaskManager
+ include TraceOutput
+
+ # The name of the application (typically 'rake')
+ attr_reader :name
+
+ # The original directory where rake was invoked.
+ attr_reader :original_dir
+
+ # Name of the actual rakefile used.
+ attr_reader :rakefile
+
+ # Number of columns on the terminal
+ attr_accessor :terminal_columns
+
+ # List of the top level task names (task names from the command line).
+ attr_reader :top_level_tasks
+
+ # Override the detected TTY output state (mostly for testing)
+ attr_writer :tty_output
+
+ DEFAULT_RAKEFILES = [
+ "rakefile",
+ "Rakefile",
+ "rakefile.rb",
+ "Rakefile.rb"
+ ].freeze
+
+ # Initialize a Rake::Application object.
+ def initialize
+ super
+ @name = "rake"
+ @rakefiles = DEFAULT_RAKEFILES.dup
+ @rakefile = nil
+ @pending_imports = []
+ @imported = []
+ @loaders = {}
+ @default_loader = Rake::DefaultLoader.new
+ @original_dir = Dir.pwd
+ @top_level_tasks = []
+ add_loader("rb", DefaultLoader.new)
+ add_loader("rf", DefaultLoader.new)
+ add_loader("rake", DefaultLoader.new)
+ @tty_output = STDOUT.tty?
+ @terminal_columns = ENV["RAKE_COLUMNS"].to_i
+
+ set_default_options
+ end
+
+ # Run the Rake application. The run method performs the following
+ # three steps:
+ #
+ # * Initialize the command line options (+init+).
+ # * Define the tasks (+load_rakefile+).
+ # * Run the top level tasks (+top_level+).
+ #
+ # If you wish to build a custom rake command, you should call
+ # +init+ on your application. Then define any tasks. Finally,
+ # call +top_level+ to run your top level tasks.
+ def run(argv = ARGV)
+ standard_exception_handling do
+ init "rake", argv
+ load_rakefile
+ top_level
+ end
+ end
+
+ # Initialize the command line parameters and app name.
+ def init(app_name="rake", argv = ARGV)
+ standard_exception_handling do
+ @name = app_name
+ begin
+ args = handle_options argv
+ rescue ArgumentError
+ # Backword compatibility for capistrano
+ args = handle_options
+ end
+ collect_command_line_tasks(args)
+ end
+ end
+
+ # Find the rakefile and then load it and any pending imports.
+ def load_rakefile
+ standard_exception_handling do
+ raw_load_rakefile
+ end
+ end
+
+ # Run the top level tasks of a Rake application.
+ def top_level
+ run_with_threads do
+ if options.show_tasks
+ display_tasks_and_comments
+ elsif options.show_prereqs
+ display_prerequisites
+ else
+ top_level_tasks.each { |task_name| invoke_task(task_name) }
+ end
+ end
+ end
+
+ # Run the given block with the thread startup and shutdown.
+ def run_with_threads
+ thread_pool.gather_history if options.job_stats == :history
+
+ yield
+
+ thread_pool.join
+ if options.job_stats
+ stats = thread_pool.statistics
+ puts "Maximum active threads: #{stats[:max_active_threads]} + main"
+ puts "Total threads in play: #{stats[:total_threads_in_play]} + main"
+ end
+ ThreadHistoryDisplay.new(thread_pool.history).show if
+ options.job_stats == :history
+ end
+
+ # Add a loader to handle imported files ending in the extension
+ # +ext+.
+ def add_loader(ext, loader)
+ ext = ".#{ext}" unless ext =~ /^\./
+ @loaders[ext] = loader
+ end
+
+ # Application options from the command line
+ def options
+ @options ||= OpenStruct.new
+ end
+
+ # Return the thread pool used for multithreaded processing.
+ def thread_pool # :nodoc:
+ @thread_pool ||= ThreadPool.new(options.thread_pool_size || Rake.suggested_thread_count-1)
+ end
+
+ # internal ----------------------------------------------------------------
+
+ # Invokes a task with arguments that are extracted from +task_string+
+ def invoke_task(task_string) # :nodoc:
+ name, args = parse_task_string(task_string)
+ t = self[name]
+ t.invoke(*args)
+ end
+
+ def parse_task_string(string) # :nodoc:
+ /^([^\[]+)(?:\[(.*)\])$/ =~ string.to_s
+
+ name = $1
+ remaining_args = $2
+
+ return string, [] unless name
+ return name, [] if remaining_args.empty?
+
+ args = []
+
+ begin
+ /\s*((?:[^\\,]|\\.)*?)\s*(?:,\s*(.*))?$/ =~ remaining_args
+
+ remaining_args = $2
+ args << $1.gsub(/\\(.)/, '\1')
+ end while remaining_args
+
+ return name, args
+ end
+
+ # Provide standard exception handling for the given block.
+ def standard_exception_handling # :nodoc:
+ yield
+ rescue SystemExit
+ # Exit silently with current status
+ raise
+ rescue OptionParser::InvalidOption => ex
+ $stderr.puts ex.message
+ exit(false)
+ rescue Exception => ex
+ # Exit with error message
+ display_error_message(ex)
+ exit_because_of_exception(ex)
+ end
+
+ # Exit the program because of an unhandled exception.
+ # (may be overridden by subclasses)
+ def exit_because_of_exception(ex) # :nodoc:
+ exit(false)
+ end
+
+ # Display the error message that caused the exception.
+ def display_error_message(ex) # :nodoc:
+ trace "#{name} aborted!"
+ display_exception_details(ex)
+ trace "Tasks: #{ex.chain}" if has_chain?(ex)
+ trace "(See full trace by running task with --trace)" unless
+ options.backtrace
+ end
+
+ def display_exception_details(ex) # :nodoc:
+ display_exception_details_seen << ex
+
+ display_exception_message_details(ex)
+ display_exception_backtrace(ex)
+ display_cause_details(ex.cause) if has_cause?(ex)
+ end
+
+ def display_cause_details(ex) # :nodoc:
+ return if display_exception_details_seen.include? ex
+
+ trace "\nCaused by:"
+ display_exception_details(ex)
+ end
+
+ def display_exception_details_seen # :nodoc:
+ Thread.current[:rake_display_exception_details_seen] ||= []
+ end
+
+ def has_cause?(ex) # :nodoc:
+ ex.respond_to?(:cause) && ex.cause
+ end
+
+ def display_exception_message_details(ex) # :nodoc:
+ if ex.instance_of?(RuntimeError)
+ trace ex.message
+ else
+ trace "#{ex.class.name}: #{ex.message}"
+ end
+ end
+
+ def display_exception_backtrace(ex) # :nodoc:
+ if options.backtrace
+ trace ex.backtrace.join("\n")
+ else
+ trace Backtrace.collapse(ex.backtrace).join("\n")
+ end
+ end
+
+ # Warn about deprecated usage.
+ #
+ # Example:
+ # Rake.application.deprecate("import", "Rake.import", caller.first)
+ #
+ def deprecate(old_usage, new_usage, call_site) # :nodoc:
+ unless options.ignore_deprecate
+ $stderr.puts "WARNING: '#{old_usage}' is deprecated. " +
+ "Please use '#{new_usage}' instead.\n" +
+ " at #{call_site}"
+ end
+ end
+
+ # Does the exception have a task invocation chain?
+ def has_chain?(exception) # :nodoc:
+ exception.respond_to?(:chain) && exception.chain
+ end
+ private :has_chain?
+
+ # True if one of the files in RAKEFILES is in the current directory.
+ # If a match is found, it is copied into @rakefile.
+ def have_rakefile # :nodoc:
+ @rakefiles.each do |fn|
+ if File.exist?(fn)
+ others = FileList.glob(fn, File::FNM_CASEFOLD)
+ return others.size == 1 ? others.first : fn
+ elsif fn == ""
+ return fn
+ end
+ end
+ return nil
+ end
+
+ # True if we are outputting to TTY, false otherwise
+ def tty_output? # :nodoc:
+ @tty_output
+ end
+
+ # We will truncate output if we are outputting to a TTY or if we've been
+ # given an explicit column width to honor
+ def truncate_output? # :nodoc:
+ tty_output? || @terminal_columns.nonzero?
+ end
+
+ # Display the tasks and comments.
+ def display_tasks_and_comments # :nodoc:
+ displayable_tasks = tasks.select { |t|
+ (options.show_all_tasks || t.comment) &&
+ t.name =~ options.show_task_pattern
+ }
+ case options.show_tasks
+ when :tasks
+ width = displayable_tasks.map { |t| t.name_with_args.length }.max || 10
+ if truncate_output?
+ max_column = terminal_width - name.size - width - 7
+ else
+ max_column = nil
+ end
+
+ displayable_tasks.each do |t|
+ printf("#{name} %-#{width}s # %s\n",
+ t.name_with_args,
+ max_column ? truncate(t.comment, max_column) : t.comment)
+ end
+ when :describe
+ displayable_tasks.each do |t|
+ puts "#{name} #{t.name_with_args}"
+ comment = t.full_comment || ""
+ comment.split("\n").each do |line|
+ puts " #{line}"
+ end
+ puts
+ end
+ when :lines
+ displayable_tasks.each do |t|
+ t.locations.each do |loc|
+ printf "#{name} %-30s %s\n", t.name_with_args, loc
+ end
+ end
+ else
+ fail "Unknown show task mode: '#{options.show_tasks}'"
+ end
+ end
+
+ def terminal_width # :nodoc:
+ if @terminal_columns.nonzero?
+ result = @terminal_columns
+ else
+ result = unix? ? dynamic_width : 80
+ end
+ (result < 10) ? 80 : result
+ rescue
+ 80
+ end
+
+ # Calculate the dynamic width of the
+ def dynamic_width # :nodoc:
+ @dynamic_width ||= (dynamic_width_stty.nonzero? || dynamic_width_tput)
+ end
+
+ def dynamic_width_stty # :nodoc:
+ %x{stty size 2>/dev/null}.split[1].to_i
+ end
+
+ def dynamic_width_tput # :nodoc:
+ %x{tput cols 2>/dev/null}.to_i
+ end
+
+ def unix? # :nodoc:
+ RbConfig::CONFIG["host_os"] =~
+ /(aix|darwin|linux|(net|free|open)bsd|cygwin|solaris|irix|hpux)/i
+ end
+
+ def windows? # :nodoc:
+ Win32.windows?
+ end
+
+ def truncate(string, width) # :nodoc:
+ if string.nil?
+ ""
+ elsif string.length <= width
+ string
+ else
+ (string[0, width - 3] || "") + "..."
+ end
+ end
+
+ # Display the tasks and prerequisites
+ def display_prerequisites # :nodoc:
+ tasks.each do |t|
+ puts "#{name} #{t.name}"
+ t.prerequisites.each { |pre| puts " #{pre}" }
+ end
+ end
+
+ def trace(*strings) # :nodoc:
+ options.trace_output ||= $stderr
+ trace_on(options.trace_output, *strings)
+ end
+
+ def sort_options(options) # :nodoc:
+ options.sort_by { |opt|
+ opt.select { |o| o =~ /^-/ }.map(&:downcase).sort.reverse
+ }
+ end
+ private :sort_options
+
+ # A list of all the standard options used in rake, suitable for
+ # passing to OptionParser.
+ def standard_rake_options # :nodoc:
+ sort_options(
+ [
+ ["--all", "-A",
+ "Show all tasks, even uncommented ones (in combination with -T or -D)",
+ lambda { |value|
+ options.show_all_tasks = value
+ }
+ ],
+ ["--backtrace=[OUT]",
+ "Enable full backtrace. OUT can be stderr (default) or stdout.",
+ lambda { |value|
+ options.backtrace = true
+ select_trace_output(options, "backtrace", value)
+ }
+ ],
+ ["--build-all", "-B",
+ "Build all prerequisites, including those which are up-to-date.",
+ lambda { |value|
+ options.build_all = true
+ }
+ ],
+ ["--comments",
+ "Show commented tasks only",
+ lambda { |value|
+ options.show_all_tasks = !value
+ }
+ ],
+ ["--describe", "-D [PATTERN]",
+ "Describe the tasks (matching optional PATTERN), then exit.",
+ lambda { |value|
+ select_tasks_to_show(options, :describe, value)
+ }
+ ],
+ ["--dry-run", "-n",
+ "Do a dry run without executing actions.",
+ lambda { |value|
+ Rake.verbose(true)
+ Rake.nowrite(true)
+ options.dryrun = true
+ options.trace = true
+ }
+ ],
+ ["--execute", "-e CODE",
+ "Execute some Ruby code and exit.",
+ lambda { |value|
+ eval(value)
+ exit
+ }
+ ],
+ ["--execute-print", "-p CODE",
+ "Execute some Ruby code, print the result, then exit.",
+ lambda { |value|
+ puts eval(value)
+ exit
+ }
+ ],
+ ["--execute-continue", "-E CODE",
+ "Execute some Ruby code, " +
+ "then continue with normal task processing.",
+ lambda { |value| eval(value) }
+ ],
+ ["--jobs", "-j [NUMBER]",
+ "Specifies the maximum number of tasks to execute in parallel. " +
+ "(default is number of CPU cores + 4)",
+ lambda { |value|
+ if value.nil? || value == ""
+ value = Float::INFINITY
+ elsif value =~ /^\d+$/
+ value = value.to_i
+ else
+ value = Rake.suggested_thread_count
+ end
+ value = 1 if value < 1
+ options.thread_pool_size = value - 1
+ }
+ ],
+ ["--job-stats [LEVEL]",
+ "Display job statistics. " +
+ "LEVEL=history displays a complete job list",
+ lambda { |value|
+ if value =~ /^history/i
+ options.job_stats = :history
+ else
+ options.job_stats = true
+ end
+ }
+ ],
+ ["--libdir", "-I LIBDIR",
+ "Include LIBDIR in the search path for required modules.",
+ lambda { |value| $:.push(value) }
+ ],
+ ["--multitask", "-m",
+ "Treat all tasks as multitasks.",
+ lambda { |value| options.always_multitask = true }
+ ],
+ ["--no-search", "--nosearch",
+ "-N", "Do not search parent directories for the Rakefile.",
+ lambda { |value| options.nosearch = true }
+ ],
+ ["--prereqs", "-P",
+ "Display the tasks and dependencies, then exit.",
+ lambda { |value| options.show_prereqs = true }
+ ],
+ ["--quiet", "-q",
+ "Do not log messages to standard output.",
+ lambda { |value| Rake.verbose(false) }
+ ],
+ ["--rakefile", "-f [FILENAME]",
+ "Use FILENAME as the rakefile to search for.",
+ lambda { |value|
+ value ||= ""
+ @rakefiles.clear
+ @rakefiles << value
+ }
+ ],
+ ["--rakelibdir", "--rakelib", "-R RAKELIBDIR",
+ "Auto-import any .rake files in RAKELIBDIR. " +
+ "(default is 'rakelib')",
+ lambda { |value|
+ options.rakelib = value.split(File::PATH_SEPARATOR)
+ }
+ ],
+ ["--require", "-r MODULE",
+ "Require MODULE before executing rakefile.",
+ lambda { |value|
+ begin
+ require value
+ rescue LoadError => ex
+ begin
+ rake_require value
+ rescue LoadError
+ raise ex
+ end
+ end
+ }
+ ],
+ ["--rules",
+ "Trace the rules resolution.",
+ lambda { |value| options.trace_rules = true }
+ ],
+ ["--silent", "-s",
+ "Like --quiet, but also suppresses the " +
+ "'in directory' announcement.",
+ lambda { |value|
+ Rake.verbose(false)
+ options.silent = true
+ }
+ ],
+ ["--suppress-backtrace PATTERN",
+ "Suppress backtrace lines matching regexp PATTERN. " +
+ "Ignored if --trace is on.",
+ lambda { |value|
+ options.suppress_backtrace_pattern = Regexp.new(value)
+ }
+ ],
+ ["--system", "-g",
+ "Using system wide (global) rakefiles " +
+ "(usually '~/.rake/*.rake').",
+ lambda { |value| options.load_system = true }
+ ],
+ ["--no-system", "--nosystem", "-G",
+ "Use standard project Rakefile search paths, " +
+ "ignore system wide rakefiles.",
+ lambda { |value| options.ignore_system = true }
+ ],
+ ["--tasks", "-T [PATTERN]",
+ "Display the tasks (matching optional PATTERN) " +
+ "with descriptions, then exit. " +
+ "-AT combination displays all of tasks contained no description.",
+ lambda { |value|
+ select_tasks_to_show(options, :tasks, value)
+ }
+ ],
+ ["--trace=[OUT]", "-t",
+ "Turn on invoke/execute tracing, enable full backtrace. " +
+ "OUT can be stderr (default) or stdout.",
+ lambda { |value|
+ options.trace = true
+ options.backtrace = true
+ select_trace_output(options, "trace", value)
+ Rake.verbose(true)
+ }
+ ],
+ ["--verbose", "-v",
+ "Log message to standard output.",
+ lambda { |value| Rake.verbose(true) }
+ ],
+ ["--version", "-V",
+ "Display the program version.",
+ lambda { |value|
+ puts "rake, version #{Rake::VERSION}"
+ exit
+ }
+ ],
+ ["--where", "-W [PATTERN]",
+ "Describe the tasks (matching optional PATTERN), then exit.",
+ lambda { |value|
+ select_tasks_to_show(options, :lines, value)
+ options.show_all_tasks = true
+ }
+ ],
+ ["--no-deprecation-warnings", "-X",
+ "Disable the deprecation warnings.",
+ lambda { |value|
+ options.ignore_deprecate = true
+ }
+ ],
+ ])
+ end
+
+ def select_tasks_to_show(options, show_tasks, value) # :nodoc:
+ options.show_tasks = show_tasks
+ options.show_task_pattern = Regexp.new(value || "")
+ Rake::TaskManager.record_task_metadata = true
+ end
+ private :select_tasks_to_show
+
+ def select_trace_output(options, trace_option, value) # :nodoc:
+ value = value.strip unless value.nil?
+ case value
+ when "stdout"
+ options.trace_output = $stdout
+ when "stderr", nil
+ options.trace_output = $stderr
+ else
+ fail CommandLineOptionError,
+ "Unrecognized --#{trace_option} option '#{value}'"
+ end
+ end
+ private :select_trace_output
+
+ # Read and handle the command line options. Returns the command line
+ # arguments that we didn't understand, which should (in theory) be just
+ # task names and env vars.
+ def handle_options(argv) # :nodoc:
+ set_default_options
+
+ OptionParser.new do |opts|
+ opts.banner = "#{Rake.application.name} [-f rakefile] {options} targets..."
+ opts.separator ""
+ opts.separator "Options are ..."
+
+ opts.on_tail("-h", "--help", "-H", "Display this help message.") do
+ puts opts
+ exit
+ end
+
+ standard_rake_options.each { |args| opts.on(*args) }
+ opts.environment("RAKEOPT")
+ end.parse(argv)
+ end
+
+ # Similar to the regular Ruby +require+ command, but will check
+ # for *.rake files in addition to *.rb files.
+ def rake_require(file_name, paths=$LOAD_PATH, loaded=$") # :nodoc:
+ fn = file_name + ".rake"
+ return false if loaded.include?(fn)
+ paths.each do |path|
+ full_path = File.join(path, fn)
+ if File.exist?(full_path)
+ Rake.load_rakefile(full_path)
+ loaded << fn
+ return true
+ end
+ end
+ fail LoadError, "Can't find #{file_name}"
+ end
+
+ def find_rakefile_location # :nodoc:
+ here = Dir.pwd
+ until (fn = have_rakefile)
+ Dir.chdir("..")
+ return nil if Dir.pwd == here || options.nosearch
+ here = Dir.pwd
+ end
+ [fn, here]
+ ensure
+ Dir.chdir(Rake.original_dir)
+ end
+
+ def print_rakefile_directory(location) # :nodoc:
+ $stderr.puts "(in #{Dir.pwd})" unless
+ options.silent or original_dir == location
+ end
+
+ def raw_load_rakefile # :nodoc:
+ rakefile, location = find_rakefile_location
+ if (! options.ignore_system) &&
+ (options.load_system || rakefile.nil?) &&
+ system_dir && File.directory?(system_dir)
+ print_rakefile_directory(location)
+ glob("#{system_dir}/*.rake") do |name|
+ add_import name
+ end
+ else
+ fail "No Rakefile found (looking for: #{@rakefiles.join(', ')})" if
+ rakefile.nil?
+ @rakefile = rakefile
+ Dir.chdir(location)
+ print_rakefile_directory(location)
+ Rake.load_rakefile(File.expand_path(@rakefile)) if
+ @rakefile && @rakefile != ""
+ options.rakelib.each do |rlib|
+ glob("#{rlib}/*.rake") do |name|
+ add_import name
+ end
+ end
+ end
+ load_imports
+ end
+
+ def glob(path, &block) # :nodoc:
+ FileList.glob(path.tr("\\", "/")).each(&block)
+ end
+ private :glob
+
+ # The directory path containing the system wide rakefiles.
+ def system_dir # :nodoc:
+ @system_dir ||=
+ begin
+ if ENV["RAKE_SYSTEM"]
+ ENV["RAKE_SYSTEM"]
+ else
+ standard_system_dir
+ end
+ end
+ end
+
+ # The standard directory containing system wide rake files.
+ if Win32.windows?
+ def standard_system_dir #:nodoc:
+ Win32.win32_system_dir
+ end
+ else
+ def standard_system_dir #:nodoc:
+ File.join(File.expand_path("~"), ".rake")
+ end
+ end
+ private :standard_system_dir
+
+ # Collect the list of tasks on the command line. If no tasks are
+ # given, return a list containing only the default task.
+ # Environmental assignments are processed at this time as well.
+ #
+ # `args` is the list of arguments to peruse to get the list of tasks.
+ # It should be the command line that was given to rake, less any
+ # recognised command-line options, which OptionParser.parse will
+ # have taken care of already.
+ def collect_command_line_tasks(args) # :nodoc:
+ @top_level_tasks = []
+ args.each do |arg|
+ if arg =~ /^(\w+)=(.*)$/m
+ ENV[$1] = $2
+ else
+ @top_level_tasks << arg unless arg =~ /^-/
+ end
+ end
+ @top_level_tasks.push(default_task_name) if @top_level_tasks.empty?
+ end
+
+ # Default task name ("default").
+ # (May be overridden by subclasses)
+ def default_task_name # :nodoc:
+ "default"
+ end
+
+ # Add a file to the list of files to be imported.
+ def add_import(fn) # :nodoc:
+ @pending_imports << fn
+ end
+
+ # Load the pending list of imported files.
+ def load_imports # :nodoc:
+ while fn = @pending_imports.shift
+ next if @imported.member?(fn)
+ fn_task = lookup(fn) and fn_task.invoke
+ ext = File.extname(fn)
+ loader = @loaders[ext] || @default_loader
+ loader.load(fn)
+ if fn_task = lookup(fn) and fn_task.needed?
+ fn_task.reenable
+ fn_task.invoke
+ loader.load(fn)
+ end
+ @imported << fn
+ end
+ end
+
+ def rakefile_location(backtrace=caller) # :nodoc:
+ backtrace.map { |t| t[/([^:]+):/, 1] }
+
+ re = /^#{@rakefile}$/
+ re = /#{re.source}/i if windows?
+
+ backtrace.find { |str| str =~ re } || ""
+ end
+
+ def set_default_options
+ options.always_multitask = false
+ options.backtrace = false
+ options.build_all = false
+ options.dryrun = false
+ options.ignore_deprecate = false
+ options.ignore_system = false
+ options.job_stats = false
+ options.load_system = false
+ options.nosearch = false
+ options.rakelib = %w[rakelib]
+ options.show_all_tasks = false
+ options.show_prereqs = false
+ options.show_task_pattern = nil
+ options.show_tasks = nil
+ options.silent = false
+ options.suppress_backtrace_pattern = nil
+ options.thread_pool_size = Rake.suggested_thread_count
+ options.trace = false
+ options.trace_output = $stderr
+ options.trace_rules = false
+ end
+
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/backtrace.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/backtrace.rb
new file mode 100644
index 00000000..31ff0545
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/backtrace.rb
@@ -0,0 +1,24 @@
+# frozen_string_literal: true
+module Rake
+ module Backtrace # :nodoc: all
+ SYS_KEYS = RbConfig::CONFIG.keys.grep(/(?:[a-z]prefix|libdir)\z/)
+ SYS_PATHS = RbConfig::CONFIG.values_at(*SYS_KEYS).uniq +
+ [ File.join(File.dirname(__FILE__), "..") ]
+
+ SUPPRESSED_PATHS = SYS_PATHS.
+ map { |s| s.tr("\\", "/") }.
+ map { |f| File.expand_path(f) }.
+ reject { |s| s.nil? || s =~ /^ *$/ }
+ SUPPRESSED_PATHS_RE = SUPPRESSED_PATHS.map { |f| Regexp.quote(f) }.join("|")
+ SUPPRESSED_PATHS_RE << "|^org\\/jruby\\/\\w+\\.java" if
+ Object.const_defined?(:RUBY_ENGINE) and RUBY_ENGINE == "jruby"
+
+ SUPPRESS_PATTERN = %r!(\A(#{SUPPRESSED_PATHS_RE})|bin/rake:\d+)!i
+
+ def self.collapse(backtrace)
+ pattern = Rake.application.options.suppress_backtrace_pattern ||
+ SUPPRESS_PATTERN
+ backtrace.reject { |elem| elem =~ pattern }
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/clean.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/clean.rb
new file mode 100644
index 00000000..5af44015
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/clean.rb
@@ -0,0 +1,78 @@
+# frozen_string_literal: true
+# The 'rake/clean' file defines two file lists (CLEAN and CLOBBER) and
+# two rake tasks (:clean and :clobber).
+#
+# [:clean] Clean up the project by deleting scratch files and backup
+# files. Add files to the CLEAN file list to have the :clean
+# target handle them.
+#
+# [:clobber] Clobber all generated and non-source files in a project.
+# The task depends on :clean, so all the clean files will
+# be deleted as well as files in the CLOBBER file list.
+# The intent of this task is to return a project to its
+# pristine, just unpacked state.
+
+require "rake"
+
+# :stopdoc:
+
+module Rake
+ module Cleaner
+ extend FileUtils
+
+ module_function
+
+ def cleanup_files(file_names)
+ file_names.each do |file_name|
+ cleanup(file_name)
+ end
+ end
+
+ def cleanup(file_name, opts={})
+ begin
+ opts = { verbose: Rake.application.options.trace }.merge(opts)
+ rm_r file_name, opts
+ rescue StandardError => ex
+ puts "Failed to remove #{file_name}: #{ex}" unless file_already_gone?(file_name)
+ end
+ end
+
+ def file_already_gone?(file_name)
+ return false if File.exist?(file_name)
+
+ path = file_name
+ prev = nil
+
+ while path = File.dirname(path)
+ return false if cant_be_deleted?(path)
+ break if [prev, "."].include?(path)
+ prev = path
+ end
+ true
+ end
+ private_class_method :file_already_gone?
+
+ def cant_be_deleted?(path_name)
+ File.exist?(path_name) &&
+ (!File.readable?(path_name) || !File.executable?(path_name))
+ end
+ private_class_method :cant_be_deleted?
+ end
+end
+
+CLEAN = ::Rake::FileList["**/*~", "**/*.bak", "**/core"]
+CLEAN.clear_exclude.exclude { |fn|
+ fn.pathmap("%f").downcase == "core" && File.directory?(fn)
+}
+
+desc "Remove any temporary products."
+task :clean do
+ Rake::Cleaner.cleanup_files(CLEAN)
+end
+
+CLOBBER = ::Rake::FileList.new
+
+desc "Remove any generated files."
+task clobber: [:clean] do
+ Rake::Cleaner.cleanup_files(CLOBBER)
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/cloneable.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/cloneable.rb
new file mode 100644
index 00000000..eddb77e2
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/cloneable.rb
@@ -0,0 +1,17 @@
+# frozen_string_literal: true
+module Rake
+ ##
+ # Mixin for creating easily cloned objects.
+
+ module Cloneable # :nodoc:
+ # The hook that is invoked by 'clone' and 'dup' methods.
+ def initialize_copy(source)
+ super
+ source.instance_variables.each do |var|
+ src_value = source.instance_variable_get(var)
+ value = src_value.clone rescue src_value
+ instance_variable_set(var, value)
+ end
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/cpu_counter.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/cpu_counter.rb
new file mode 100644
index 00000000..f3bf6d63
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/cpu_counter.rb
@@ -0,0 +1,107 @@
+# frozen_string_literal: true
+module Rake
+
+ # Based on a script at:
+ # http://stackoverflow.com/questions/891537/ruby-detect-number-of-cpus-installed
+ class CpuCounter # :nodoc: all
+ def self.count
+ new.count_with_default
+ end
+
+ def count_with_default(default=4)
+ count || default
+ rescue StandardError
+ default
+ end
+
+ begin
+ require "etc"
+ rescue LoadError
+ else
+ if Etc.respond_to?(:nprocessors)
+ def count
+ return Etc.nprocessors
+ end
+ end
+ end
+ end
+end
+
+unless Rake::CpuCounter.method_defined?(:count)
+ Rake::CpuCounter.class_eval <<-'end;', __FILE__, __LINE__+1
+ require 'rbconfig'
+
+ def count
+ if defined?(Java::Java)
+ count_via_java_runtime
+ else
+ case RbConfig::CONFIG['host_os']
+ when /linux/
+ count_via_cpuinfo
+ when /darwin|bsd/
+ count_via_sysctl
+ when /mswin|mingw/
+ count_via_win32
+ else
+ # Try everything
+ count_via_win32 ||
+ count_via_sysctl ||
+ count_via_cpuinfo
+ end
+ end
+ end
+
+ def count_via_java_runtime
+ Java::Java.lang.Runtime.getRuntime.availableProcessors
+ rescue StandardError
+ nil
+ end
+
+ def count_via_win32
+ require 'win32ole'
+ wmi = WIN32OLE.connect("winmgmts://")
+ cpu = wmi.ExecQuery("select NumberOfCores from Win32_Processor") # TODO count hyper-threaded in this
+ cpu.to_enum.first.NumberOfCores
+ rescue StandardError, LoadError
+ nil
+ end
+
+ def count_via_cpuinfo
+ open('/proc/cpuinfo') { |f| f.readlines }.grep(/processor/).size
+ rescue StandardError
+ nil
+ end
+
+ def count_via_sysctl
+ run 'sysctl', '-n', 'hw.ncpu'
+ end
+
+ def run(command, *args)
+ cmd = resolve_command(command)
+ if cmd
+ IO.popen [cmd, *args] do |io|
+ io.read.to_i
+ end
+ else
+ nil
+ end
+ end
+
+ def resolve_command(command)
+ look_for_command("/usr/sbin", command) ||
+ look_for_command("/sbin", command) ||
+ in_path_command(command)
+ end
+
+ def look_for_command(dir, command)
+ path = File.join(dir, command)
+ File.exist?(path) ? path : nil
+ end
+
+ def in_path_command(command)
+ IO.popen ['which', command] do |io|
+ io.eof? ? nil : command
+ end
+ end
+ end;
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/default_loader.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/default_loader.rb
new file mode 100644
index 00000000..d3b4650d
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/default_loader.rb
@@ -0,0 +1,15 @@
+# frozen_string_literal: true
+module Rake
+
+ # Default Rakefile loader used by +import+.
+ class DefaultLoader
+
+ ##
+ # Loads a rakefile into the current application from +fn+
+
+ def load(fn)
+ Rake.load_rakefile(File.expand_path(fn))
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/dsl_definition.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/dsl_definition.rb
new file mode 100644
index 00000000..3962c167
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/dsl_definition.rb
@@ -0,0 +1,195 @@
+# frozen_string_literal: true
+# Rake DSL functions.
+require "rake/file_utils_ext"
+
+module Rake
+
+ ##
+ # DSL is a module that provides #task, #desc, #namespace, etc. Use this
+ # when you'd like to use rake outside the top level scope.
+ #
+ # For a Rakefile you run from the command line this module is automatically
+ # included.
+
+ module DSL
+
+ #--
+ # Include the FileUtils file manipulation functions in the top
+ # level module, but mark them private so that they don't
+ # unintentionally define methods on other objects.
+ #++
+
+ include FileUtilsExt
+ private(*FileUtils.instance_methods(false))
+ private(*FileUtilsExt.instance_methods(false))
+
+ private
+
+ # :call-seq:
+ # task task_name
+ # task task_name: dependencies
+ # task task_name, arguments => dependencies
+ #
+ # Declare a basic task. The +task_name+ is always the first argument. If
+ # the task name contains a ":" it is defined in that namespace.
+ #
+ # The +dependencies+ may be a single task name or an Array of task names.
+ # The +argument+ (a single name) or +arguments+ (an Array of names) define
+ # the arguments provided to the task.
+ #
+ # The task, argument and dependency names may be either symbols or
+ # strings.
+ #
+ # A task with a single dependency:
+ #
+ # task clobber: %w[clean] do
+ # rm_rf "html"
+ # end
+ #
+ # A task with an argument and a dependency:
+ #
+ # task :package, [:version] => :test do |t, args|
+ # # ...
+ # end
+ #
+ # To invoke this task from the command line:
+ #
+ # $ rake package[1.2.3]
+ #
+ def task(*args, &block) # :doc:
+ Rake::Task.define_task(*args, &block)
+ end
+
+ # Declare a file task.
+ #
+ # Example:
+ # file "config.cfg" => ["config.template"] do
+ # open("config.cfg", "w") do |outfile|
+ # open("config.template") do |infile|
+ # while line = infile.gets
+ # outfile.puts line
+ # end
+ # end
+ # end
+ # end
+ #
+ def file(*args, &block) # :doc:
+ Rake::FileTask.define_task(*args, &block)
+ end
+
+ # Declare a file creation task.
+ # (Mainly used for the directory command).
+ def file_create(*args, &block)
+ Rake::FileCreationTask.define_task(*args, &block)
+ end
+
+ # Declare a set of files tasks to create the given directories on
+ # demand.
+ #
+ # Example:
+ # directory "testdata/doc"
+ #
+ def directory(*args, &block) # :doc:
+ result = file_create(*args, &block)
+ dir, _ = *Rake.application.resolve_args(args)
+ dir = Rake.from_pathname(dir)
+ Rake.each_dir_parent(dir) do |d|
+ file_create d do |t|
+ mkdir_p t.name unless File.exist?(t.name)
+ end
+ end
+ result
+ end
+
+ # Declare a task that performs its prerequisites in
+ # parallel. Multitasks does *not* guarantee that its prerequisites
+ # will execute in any given order (which is obvious when you think
+ # about it)
+ #
+ # Example:
+ # multitask deploy: %w[deploy_gem deploy_rdoc]
+ #
+ def multitask(*args, &block) # :doc:
+ Rake::MultiTask.define_task(*args, &block)
+ end
+
+ # Create a new rake namespace and use it for evaluating the given
+ # block. Returns a NameSpace object that can be used to lookup
+ # tasks defined in the namespace.
+ #
+ # Example:
+ #
+ # ns = namespace "nested" do
+ # # the "nested:run" task
+ # task :run
+ # end
+ # task_run = ns[:run] # find :run in the given namespace.
+ #
+ # Tasks can also be defined in a namespace by using a ":" in the task
+ # name:
+ #
+ # task "nested:test" do
+ # # ...
+ # end
+ #
+ def namespace(name=nil, &block) # :doc:
+ name = name.to_s if name.kind_of?(Symbol)
+ name = name.to_str if name.respond_to?(:to_str)
+ unless name.kind_of?(String) || name.nil?
+ raise ArgumentError, "Expected a String or Symbol for a namespace name"
+ end
+ Rake.application.in_namespace(name, &block)
+ end
+
+ # Declare a rule for auto-tasks.
+ #
+ # Example:
+ # rule '.o' => '.c' do |t|
+ # sh 'cc', '-o', t.name, t.source
+ # end
+ #
+ def rule(*args, &block) # :doc:
+ Rake::Task.create_rule(*args, &block)
+ end
+
+ # Describes the next rake task. Duplicate descriptions are discarded.
+ # Descriptions are shown with rake -T
(up to the first
+ # sentence) and rake -D
(the entire description).
+ #
+ # Example:
+ # desc "Run the Unit Tests"
+ # task test: [:build]
+ # # ... run tests
+ # end
+ #
+ def desc(description) # :doc:
+ Rake.application.last_description = description
+ end
+
+ # Import the partial Rakefiles +fn+. Imported files are loaded
+ # _after_ the current file is completely loaded. This allows the
+ # import statement to appear anywhere in the importing file, and yet
+ # allowing the imported files to depend on objects defined in the
+ # importing file.
+ #
+ # A common use of the import statement is to include files
+ # containing dependency declarations.
+ #
+ # See also the --rakelibdir command line option.
+ #
+ # Example:
+ # import ".depend", "my_rules"
+ #
+ def import(*fns) # :doc:
+ fns.each do |fn|
+ Rake.application.add_import(fn)
+ end
+ end
+ end
+ extend FileUtilsExt
+end
+
+# Extend the main object with the DSL commands. This allows top-level
+# calls to task, etc. to work from a Rakefile without polluting the
+# object inheritance tree.
+self.extend Rake::DSL
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/early_time.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/early_time.rb
new file mode 100644
index 00000000..80cc6bfa
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/early_time.rb
@@ -0,0 +1,22 @@
+# frozen_string_literal: true
+module Rake
+
+ # EarlyTime is a fake timestamp that occurs _before_ any other time value.
+ class EarlyTime
+ include Comparable
+ include Singleton
+
+ ##
+ # The EarlyTime always comes before +other+!
+
+ def <=>(other)
+ -1
+ end
+
+ def to_s # :nodoc:
+ ""
+ end
+ end
+
+ EARLY = EarlyTime.instance
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/ext/core.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/ext/core.rb
new file mode 100644
index 00000000..226f2125
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/ext/core.rb
@@ -0,0 +1,26 @@
+# frozen_string_literal: true
+class Module
+ # Check for an existing method in the current class before extending. If
+ # the method already exists, then a warning is printed and the extension is
+ # not added. Otherwise the block is yielded and any definitions in the
+ # block will take effect.
+ #
+ # Usage:
+ #
+ # class String
+ # rake_extension("xyz") do
+ # def xyz
+ # ...
+ # end
+ # end
+ # end
+ #
+ def rake_extension(method) # :nodoc:
+ if method_defined?(method)
+ $stderr.puts "WARNING: Possible conflict with Rake extension: " +
+ "#{self}##{method} already exists"
+ else
+ yield
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/ext/string.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/ext/string.rb
new file mode 100644
index 00000000..c70236ae
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/ext/string.rb
@@ -0,0 +1,176 @@
+# frozen_string_literal: true
+require "rake/ext/core"
+
+class String
+
+ rake_extension("ext") do
+ # Replace the file extension with +newext+. If there is no extension on
+ # the string, append the new extension to the end. If the new extension
+ # is not given, or is the empty string, remove any existing extension.
+ #
+ # +ext+ is a user added method for the String class.
+ #
+ # This String extension comes from Rake
+ def ext(newext="")
+ return self.dup if [".", ".."].include? self
+ if newext != ""
+ newext = "." + newext unless newext =~ /^\./
+ end
+ self.chomp(File.extname(self)) << newext
+ end
+ end
+
+ rake_extension("pathmap") do
+ # Explode a path into individual components. Used by +pathmap+.
+ #
+ # This String extension comes from Rake
+ def pathmap_explode
+ head, tail = File.split(self)
+ return [self] if head == self
+ return [tail] if head == "." || tail == "/"
+ return [head, tail] if head == "/"
+ return head.pathmap_explode + [tail]
+ end
+ protected :pathmap_explode
+
+ # Extract a partial path from the path. Include +n+ directories from the
+ # front end (left hand side) if +n+ is positive. Include |+n+|
+ # directories from the back end (right hand side) if +n+ is negative.
+ #
+ # This String extension comes from Rake
+ def pathmap_partial(n)
+ dirs = File.dirname(self).pathmap_explode
+ partial_dirs =
+ if n > 0
+ dirs[0...n]
+ elsif n < 0
+ dirs.reverse[0...-n].reverse
+ else
+ "."
+ end
+ File.join(partial_dirs)
+ end
+ protected :pathmap_partial
+
+ # Perform the pathmap replacement operations on the given path. The
+ # patterns take the form 'pat1,rep1;pat2,rep2...'.
+ #
+ # This String extension comes from Rake
+ def pathmap_replace(patterns, &block)
+ result = self
+ patterns.split(";").each do |pair|
+ pattern, replacement = pair.split(",")
+ pattern = Regexp.new(pattern)
+ if replacement == "*" && block_given?
+ result = result.sub(pattern, &block)
+ elsif replacement
+ result = result.sub(pattern, replacement)
+ else
+ result = result.sub(pattern, "")
+ end
+ end
+ result
+ end
+ protected :pathmap_replace
+
+ # Map the path according to the given specification. The specification
+ # controls the details of the mapping. The following special patterns are
+ # recognized:
+ #
+ # %p :: The complete path.
+ # %f :: The base file name of the path, with its file extension,
+ # but without any directories.
+ # %n :: The file name of the path without its file extension.
+ # %d :: The directory list of the path.
+ # %x :: The file extension of the path. An empty string if there
+ # is no extension.
+ # %X :: Everything *but* the file extension.
+ # %s :: The alternate file separator if defined, otherwise use #
+ # the standard file separator.
+ # %% :: A percent sign.
+ #
+ # The %d specifier can also have a numeric prefix (e.g. '%2d').
+ # If the number is positive, only return (up to) +n+ directories in the
+ # path, starting from the left hand side. If +n+ is negative, return (up
+ # to) +n+ directories from the right hand side of the path.
+ #
+ # Examples:
+ #
+ # 'a/b/c/d/file.txt'.pathmap("%2d") => 'a/b'
+ # 'a/b/c/d/file.txt'.pathmap("%-2d") => 'c/d'
+ #
+ # Also the %d, %p, %f, %n,
+ # %x, and %X operators can take a pattern/replacement
+ # argument to perform simple string substitutions on a particular part of
+ # the path. The pattern and replacement are separated by a comma and are
+ # enclosed by curly braces. The replacement spec comes after the %
+ # character but before the operator letter. (e.g. "%{old,new}d").
+ # Multiple replacement specs should be separated by semi-colons (e.g.
+ # "%{old,new;src,bin}d").
+ #
+ # Regular expressions may be used for the pattern, and back refs may be
+ # used in the replacement text. Curly braces, commas and semi-colons are
+ # excluded from both the pattern and replacement text (let's keep parsing
+ # reasonable).
+ #
+ # For example:
+ #
+ # "src/org/onestepback/proj/A.java".pathmap("%{^src,class}X.class")
+ #
+ # returns:
+ #
+ # "class/org/onestepback/proj/A.class"
+ #
+ # If the replacement text is '*', then a block may be provided to perform
+ # some arbitrary calculation for the replacement.
+ #
+ # For example:
+ #
+ # "/path/to/file.TXT".pathmap("%X%{.*,*}x") { |ext|
+ # ext.downcase
+ # }
+ #
+ # Returns:
+ #
+ # "/path/to/file.txt"
+ #
+ # This String extension comes from Rake
+ def pathmap(spec=nil, &block)
+ return self if spec.nil?
+ result = "".dup
+ spec.scan(/%\{[^}]*\}-?\d*[sdpfnxX%]|%-?\d+d|%.|[^%]+/) do |frag|
+ case frag
+ when "%f"
+ result << File.basename(self)
+ when "%n"
+ result << File.basename(self).ext
+ when "%d"
+ result << File.dirname(self)
+ when "%x"
+ result << File.extname(self)
+ when "%X"
+ result << self.ext
+ when "%p"
+ result << self
+ when "%s"
+ result << (File::ALT_SEPARATOR || File::SEPARATOR)
+ when "%-"
+ # do nothing
+ when "%%"
+ result << "%"
+ when /%(-?\d+)d/
+ result << pathmap_partial($1.to_i)
+ when /^%\{([^}]*)\}(\d*[dpfnxX])/
+ patterns, operator = $1, $2
+ result << pathmap("%" + operator).pathmap_replace(patterns, &block)
+ when /^%/
+ fail ArgumentError, "Unknown pathmap specifier #{frag} in '#{spec}'"
+ else
+ result << frag
+ end
+ end
+ result
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_creation_task.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_creation_task.rb
new file mode 100644
index 00000000..2eb251bf
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_creation_task.rb
@@ -0,0 +1,25 @@
+# frozen_string_literal: true
+require "rake/file_task"
+require "rake/early_time"
+
+module Rake
+
+ # A FileCreationTask is a file task that when used as a dependency will be
+ # needed if and only if the file has not been created. Once created, it is
+ # not re-triggered if any of its dependencies are newer, nor does trigger
+ # any rebuilds of tasks that depend on it whenever it is updated.
+ #
+ class FileCreationTask < FileTask
+ # Is this file task needed? Yes if it doesn't exist.
+ def needed?
+ ! File.exist?(name)
+ end
+
+ # Time stamp for file creation task. This time stamp is earlier
+ # than any other time stamp.
+ def timestamp
+ Rake::EARLY
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_list.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_list.rb
new file mode 100644
index 00000000..e27de8db
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_list.rb
@@ -0,0 +1,435 @@
+# frozen_string_literal: true
+require "rake/cloneable"
+require "rake/file_utils_ext"
+require "rake/ext/string"
+
+module Rake
+
+ ##
+ # A FileList is essentially an array with a few helper methods defined to
+ # make file manipulation a bit easier.
+ #
+ # FileLists are lazy. When given a list of glob patterns for possible files
+ # to be included in the file list, instead of searching the file structures
+ # to find the files, a FileList holds the pattern for latter use.
+ #
+ # This allows us to define a number of FileList to match any number of
+ # files, but only search out the actual files when then FileList itself is
+ # actually used. The key is that the first time an element of the
+ # FileList/Array is requested, the pending patterns are resolved into a real
+ # list of file names.
+ #
+ class FileList
+
+ include Cloneable
+
+ # == Method Delegation
+ #
+ # The lazy evaluation magic of FileLists happens by implementing all the
+ # array specific methods to call +resolve+ before delegating the heavy
+ # lifting to an embedded array object (@items).
+ #
+ # In addition, there are two kinds of delegation calls. The regular kind
+ # delegates to the @items array and returns the result directly. Well,
+ # almost directly. It checks if the returned value is the @items object
+ # itself, and if so will return the FileList object instead.
+ #
+ # The second kind of delegation call is used in methods that normally
+ # return a new Array object. We want to capture the return value of these
+ # methods and wrap them in a new FileList object. We enumerate these
+ # methods in the +SPECIAL_RETURN+ list below.
+
+ # List of array methods (that are not in +Object+) that need to be
+ # delegated.
+ ARRAY_METHODS = (Array.instance_methods - Object.instance_methods).map(&:to_s)
+
+ # List of additional methods that must be delegated.
+ MUST_DEFINE = %w[inspect <=>]
+
+ # List of methods that should not be delegated here (we define special
+ # versions of them explicitly below).
+ MUST_NOT_DEFINE = %w[to_a to_ary partition * <<]
+
+ # List of delegated methods that return new array values which need
+ # wrapping.
+ SPECIAL_RETURN = %w[
+ map collect sort sort_by select find_all reject grep
+ compact flatten uniq values_at
+ + - & |
+ ]
+
+ DELEGATING_METHODS = (ARRAY_METHODS + MUST_DEFINE - MUST_NOT_DEFINE).map(&:to_s).sort.uniq
+
+ # Now do the delegation.
+ DELEGATING_METHODS.each do |sym|
+ if SPECIAL_RETURN.include?(sym)
+ ln = __LINE__ + 1
+ class_eval %{
+ def #{sym}(*args, &block)
+ resolve
+ result = @items.send(:#{sym}, *args, &block)
+ self.class.new.import(result)
+ end
+ }, __FILE__, ln
+ else
+ ln = __LINE__ + 1
+ class_eval %{
+ def #{sym}(*args, &block)
+ resolve
+ result = @items.send(:#{sym}, *args, &block)
+ result.object_id == @items.object_id ? self : result
+ end
+ }, __FILE__, ln
+ end
+ end
+
+ GLOB_PATTERN = %r{[*?\[\{]}
+
+ # Create a file list from the globbable patterns given. If you wish to
+ # perform multiple includes or excludes at object build time, use the
+ # "yield self" pattern.
+ #
+ # Example:
+ # file_list = FileList.new('lib/**/*.rb', 'test/test*.rb')
+ #
+ # pkg_files = FileList.new('lib/**/*') do |fl|
+ # fl.exclude(/\bCVS\b/)
+ # end
+ #
+ def initialize(*patterns)
+ @pending_add = []
+ @pending = false
+ @exclude_patterns = DEFAULT_IGNORE_PATTERNS.dup
+ @exclude_procs = DEFAULT_IGNORE_PROCS.dup
+ @items = []
+ patterns.each { |pattern| include(pattern) }
+ yield self if block_given?
+ end
+
+ # Add file names defined by glob patterns to the file list. If an array
+ # is given, add each element of the array.
+ #
+ # Example:
+ # file_list.include("*.java", "*.cfg")
+ # file_list.include %w( math.c lib.h *.o )
+ #
+ def include(*filenames)
+ # TODO: check for pending
+ filenames.each do |fn|
+ if fn.respond_to? :to_ary
+ include(*fn.to_ary)
+ else
+ @pending_add << Rake.from_pathname(fn)
+ end
+ end
+ @pending = true
+ self
+ end
+ alias :add :include
+
+ # Register a list of file name patterns that should be excluded from the
+ # list. Patterns may be regular expressions, glob patterns or regular
+ # strings. In addition, a block given to exclude will remove entries that
+ # return true when given to the block.
+ #
+ # Note that glob patterns are expanded against the file system. If a file
+ # is explicitly added to a file list, but does not exist in the file
+ # system, then an glob pattern in the exclude list will not exclude the
+ # file.
+ #
+ # Examples:
+ # FileList['a.c', 'b.c'].exclude("a.c") => ['b.c']
+ # FileList['a.c', 'b.c'].exclude(/^a/) => ['b.c']
+ #
+ # If "a.c" is a file, then ...
+ # FileList['a.c', 'b.c'].exclude("a.*") => ['b.c']
+ #
+ # If "a.c" is not a file, then ...
+ # FileList['a.c', 'b.c'].exclude("a.*") => ['a.c', 'b.c']
+ #
+ def exclude(*patterns, &block)
+ patterns.each do |pat|
+ if pat.respond_to? :to_ary
+ exclude(*pat.to_ary)
+ else
+ @exclude_patterns << Rake.from_pathname(pat)
+ end
+ end
+ @exclude_procs << block if block_given?
+ resolve_exclude unless @pending
+ self
+ end
+
+ # Clear all the exclude patterns so that we exclude nothing.
+ def clear_exclude
+ @exclude_patterns = []
+ @exclude_procs = []
+ self
+ end
+
+ # A FileList is equal through array equality.
+ def ==(array)
+ to_ary == array
+ end
+
+ # Return the internal array object.
+ def to_a
+ resolve
+ @items
+ end
+
+ # Return the internal array object.
+ def to_ary
+ to_a
+ end
+
+ # Lie about our class.
+ def is_a?(klass)
+ klass == Array || super(klass)
+ end
+ alias kind_of? is_a?
+
+ # Redefine * to return either a string or a new file list.
+ def *(other)
+ result = @items * other
+ case result
+ when Array
+ self.class.new.import(result)
+ else
+ result
+ end
+ end
+
+ def <<(obj)
+ resolve
+ @items << Rake.from_pathname(obj)
+ self
+ end
+
+ # Resolve all the pending adds now.
+ def resolve
+ if @pending
+ @pending = false
+ @pending_add.each do |fn| resolve_add(fn) end
+ @pending_add = []
+ resolve_exclude
+ end
+ self
+ end
+
+ def resolve_add(fn) # :nodoc:
+ case fn
+ when GLOB_PATTERN
+ add_matching(fn)
+ else
+ self << fn
+ end
+ end
+ private :resolve_add
+
+ def resolve_exclude # :nodoc:
+ reject! { |fn| excluded_from_list?(fn) }
+ self
+ end
+ private :resolve_exclude
+
+ # Return a new FileList with the results of running +sub+ against each
+ # element of the original list.
+ #
+ # Example:
+ # FileList['a.c', 'b.c'].sub(/\.c$/, '.o') => ['a.o', 'b.o']
+ #
+ def sub(pat, rep)
+ inject(self.class.new) { |res, fn| res << fn.sub(pat, rep) }
+ end
+
+ # Return a new FileList with the results of running +gsub+ against each
+ # element of the original list.
+ #
+ # Example:
+ # FileList['lib/test/file', 'x/y'].gsub(/\//, "\\")
+ # => ['lib\\test\\file', 'x\\y']
+ #
+ def gsub(pat, rep)
+ inject(self.class.new) { |res, fn| res << fn.gsub(pat, rep) }
+ end
+
+ # Same as +sub+ except that the original file list is modified.
+ def sub!(pat, rep)
+ each_with_index { |fn, i| self[i] = fn.sub(pat, rep) }
+ self
+ end
+
+ # Same as +gsub+ except that the original file list is modified.
+ def gsub!(pat, rep)
+ each_with_index { |fn, i| self[i] = fn.gsub(pat, rep) }
+ self
+ end
+
+ # Apply the pathmap spec to each of the included file names, returning a
+ # new file list with the modified paths. (See String#pathmap for
+ # details.)
+ def pathmap(spec=nil, &block)
+ collect { |fn| fn.pathmap(spec, &block) }
+ end
+
+ # Return a new FileList with String#ext method applied to
+ # each member of the array.
+ #
+ # This method is a shortcut for:
+ #
+ # array.collect { |item| item.ext(newext) }
+ #
+ # +ext+ is a user added method for the Array class.
+ def ext(newext="")
+ collect { |fn| fn.ext(newext) }
+ end
+
+ # Grep each of the files in the filelist using the given pattern. If a
+ # block is given, call the block on each matching line, passing the file
+ # name, line number, and the matching line of text. If no block is given,
+ # a standard emacs style file:linenumber:line message will be printed to
+ # standard out. Returns the number of matched items.
+ def egrep(pattern, *options)
+ matched = 0
+ each do |fn|
+ begin
+ open(fn, "r", *options) do |inf|
+ count = 0
+ inf.each do |line|
+ count += 1
+ if pattern.match(line)
+ matched += 1
+ if block_given?
+ yield fn, count, line
+ else
+ puts "#{fn}:#{count}:#{line}"
+ end
+ end
+ end
+ end
+ rescue StandardError => ex
+ $stderr.puts "Error while processing '#{fn}': #{ex}"
+ end
+ end
+ matched
+ end
+
+ # Return a new file list that only contains file names from the current
+ # file list that exist on the file system.
+ def existing
+ select { |fn| File.exist?(fn) }.uniq
+ end
+
+ # Modify the current file list so that it contains only file name that
+ # exist on the file system.
+ def existing!
+ resolve
+ @items = @items.select { |fn| File.exist?(fn) }.uniq
+ self
+ end
+
+ # FileList version of partition. Needed because the nested arrays should
+ # be FileLists in this version.
+ def partition(&block) # :nodoc:
+ resolve
+ result = @items.partition(&block)
+ [
+ self.class.new.import(result[0]),
+ self.class.new.import(result[1]),
+ ]
+ end
+
+ # Convert a FileList to a string by joining all elements with a space.
+ def to_s
+ resolve
+ self.join(" ")
+ end
+
+ # Add matching glob patterns.
+ def add_matching(pattern)
+ self.class.glob(pattern).each do |fn|
+ self << fn unless excluded_from_list?(fn)
+ end
+ end
+ private :add_matching
+
+ # Should the given file name be excluded from the list?
+ #
+ # NOTE: This method was formerly named "exclude?", but Rails
+ # introduced an exclude? method as an array method and setup a
+ # conflict with file list. We renamed the method to avoid
+ # confusion. If you were using "FileList#exclude?" in your user
+ # code, you will need to update.
+ def excluded_from_list?(fn)
+ return true if @exclude_patterns.any? do |pat|
+ case pat
+ when Regexp
+ fn =~ pat
+ when GLOB_PATTERN
+ flags = File::FNM_PATHNAME
+ # Ruby <= 1.9.3 does not support File::FNM_EXTGLOB
+ flags |= File::FNM_EXTGLOB if defined? File::FNM_EXTGLOB
+ File.fnmatch?(pat, fn, flags)
+ else
+ fn == pat
+ end
+ end
+ @exclude_procs.any? { |p| p.call(fn) }
+ end
+
+ DEFAULT_IGNORE_PATTERNS = [
+ /(^|[\/\\])CVS([\/\\]|$)/,
+ /(^|[\/\\])\.svn([\/\\]|$)/,
+ /\.bak$/,
+ /~$/
+ ]
+ DEFAULT_IGNORE_PROCS = [
+ proc { |fn| fn =~ /(^|[\/\\])core$/ && ! File.directory?(fn) }
+ ]
+
+ def import(array) # :nodoc:
+ @items = array
+ self
+ end
+
+ class << self
+ # Create a new file list including the files listed. Similar to:
+ #
+ # FileList.new(*args)
+ def [](*args)
+ new(*args)
+ end
+
+ # Get a sorted list of files matching the pattern. This method
+ # should be preferred to Dir[pattern] and Dir.glob(pattern) because
+ # the files returned are guaranteed to be sorted.
+ def glob(pattern, *args)
+ Dir.glob(pattern, *args).sort
+ end
+ end
+ end
+end
+
+module Rake
+ class << self
+
+ # Yield each file or directory component.
+ def each_dir_parent(dir) # :nodoc:
+ old_length = nil
+ while dir != "." && dir.length != old_length
+ yield(dir)
+ old_length = dir.length
+ dir = File.dirname(dir)
+ end
+ end
+
+ # Convert Pathname and Pathname-like objects to strings;
+ # leave everything else alone
+ def from_pathname(path) # :nodoc:
+ path = path.to_path if path.respond_to?(:to_path)
+ path = path.to_str if path.respond_to?(:to_str)
+ path
+ end
+ end
+end # module Rake
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_task.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_task.rb
new file mode 100644
index 00000000..364d8e39
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_task.rb
@@ -0,0 +1,54 @@
+# frozen_string_literal: true
+require "rake/task.rb"
+require "rake/early_time"
+
+module Rake
+
+ # A FileTask is a task that includes time based dependencies. If any of a
+ # FileTask's prerequisites have a timestamp that is later than the file
+ # represented by this task, then the file must be rebuilt (using the
+ # supplied actions).
+ #
+ class FileTask < Task
+
+ # Is this file task needed? Yes if it doesn't exist, or if its time stamp
+ # is out of date.
+ def needed?
+ ! File.exist?(name) || out_of_date?(timestamp) || @application.options.build_all
+ end
+
+ # Time stamp for file task.
+ def timestamp
+ if File.exist?(name)
+ File.mtime(name.to_s)
+ else
+ Rake::LATE
+ end
+ end
+
+ private
+
+ # Are there any prerequisites with a later time than the given time stamp?
+ def out_of_date?(stamp)
+ all_prerequisite_tasks.any? { |prereq|
+ prereq_task = application[prereq, @scope]
+ if prereq_task.instance_of?(Rake::FileTask)
+ prereq_task.timestamp > stamp || @application.options.build_all
+ else
+ prereq_task.timestamp > stamp
+ end
+ }
+ end
+
+ # ----------------------------------------------------------------
+ # Task class methods.
+ #
+ class << self
+ # Apply the scope to the task name according to the rules for this kind
+ # of task. File based tasks ignore the scope when creating the name.
+ def scope_name(scope, task_name)
+ Rake.from_pathname(task_name)
+ end
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_utils.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_utils.rb
new file mode 100644
index 00000000..3439befa
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_utils.rb
@@ -0,0 +1,137 @@
+# frozen_string_literal: true
+require "rbconfig"
+require "fileutils"
+
+#--
+# This a FileUtils extension that defines several additional commands to be
+# added to the FileUtils utility functions.
+module FileUtils
+ # Path to the currently running Ruby program
+ RUBY = ENV["RUBY"] || File.join(
+ RbConfig::CONFIG["bindir"],
+ RbConfig::CONFIG["ruby_install_name"] + RbConfig::CONFIG["EXEEXT"]).
+ sub(/.*\s.*/m, '"\&"')
+
+ # Run the system command +cmd+. If multiple arguments are given the command
+ # is run directly (without the shell, same semantics as Kernel::exec and
+ # Kernel::system).
+ #
+ # It is recommended you use the multiple argument form over interpolating
+ # user input for both usability and security reasons. With the multiple
+ # argument form you can easily process files with spaces or other shell
+ # reserved characters in them. With the multiple argument form your rake
+ # tasks are not vulnerable to users providing an argument like
+ # ; rm # -rf /
.
+ #
+ # If a block is given, upon command completion the block is called with an
+ # OK flag (true on a zero exit status) and a Process::Status object.
+ # Without a block a RuntimeError is raised when the command exits non-zero.
+ #
+ # Examples:
+ #
+ # sh 'ls -ltr'
+ #
+ # sh 'ls', 'file with spaces'
+ #
+ # # check exit status after command runs
+ # sh %{grep pattern file} do |ok, res|
+ # if ! ok
+ # puts "pattern not found (status = #{res.exitstatus})"
+ # end
+ # end
+ #
+ def sh(*cmd, &block)
+ options = (Hash === cmd.last) ? cmd.pop : {}
+ shell_runner = block_given? ? block : create_shell_runner(cmd)
+
+ set_verbose_option(options)
+ verbose = options.delete :verbose
+ noop = options.delete(:noop) || Rake::FileUtilsExt.nowrite_flag
+
+ Rake.rake_output_message sh_show_command cmd if verbose
+
+ unless noop
+ res = (Hash === cmd.last) ? system(*cmd) : system(*cmd, options)
+ status = $?
+ status = Rake::PseudoStatus.new(1) if !res && status.nil?
+ shell_runner.call(res, status)
+ end
+ end
+
+ def create_shell_runner(cmd) # :nodoc:
+ show_command = sh_show_command cmd
+ show_command = show_command[0, 42] + "..." unless $trace
+
+ lambda do |ok, status|
+ ok or
+ fail "Command failed with status (#{status.exitstatus}): " +
+ "[#{show_command}]"
+ end
+ end
+ private :create_shell_runner
+
+ def sh_show_command(cmd) # :nodoc:
+ cmd = cmd.dup
+
+ if Hash === cmd.first
+ env = cmd.first
+ env = env.map { |name, value| "#{name}=#{value}" }.join " "
+ cmd[0] = env
+ end
+
+ cmd.join " "
+ end
+ private :sh_show_command
+
+ def set_verbose_option(options) # :nodoc:
+ unless options.key? :verbose
+ options[:verbose] =
+ (Rake::FileUtilsExt.verbose_flag == Rake::FileUtilsExt::DEFAULT) ||
+ Rake::FileUtilsExt.verbose_flag
+ end
+ end
+ private :set_verbose_option
+
+ # Run a Ruby interpreter with the given arguments.
+ #
+ # Example:
+ # ruby %{-pe '$_.upcase!' 1
+ sh(*([RUBY] + args + [options]), &block)
+ else
+ sh("#{RUBY} #{args.first}", options, &block)
+ end
+ end
+
+ LN_SUPPORTED = [true]
+
+ # Attempt to do a normal file link, but fall back to a copy if the link
+ # fails.
+ def safe_ln(*args)
+ if ! LN_SUPPORTED[0]
+ cp(*args)
+ else
+ begin
+ ln(*args)
+ rescue StandardError, NotImplementedError
+ LN_SUPPORTED[0] = false
+ cp(*args)
+ end
+ end
+ end
+
+ # Split a file path into individual directory names.
+ #
+ # Example:
+ # split_all("a/b/c") => ['a', 'b', 'c']
+ #
+ def split_all(path)
+ head, tail = File.split(path)
+ return [tail] if head == "." || tail == "/"
+ return [head, tail] if head == "/"
+ return split_all(head) + [tail]
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_utils_ext.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_utils_ext.rb
new file mode 100644
index 00000000..bf558b74
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/file_utils_ext.rb
@@ -0,0 +1,145 @@
+# frozen_string_literal: true
+require "rake/file_utils"
+
+module Rake
+ #
+ # FileUtilsExt provides a custom version of the FileUtils methods
+ # that respond to the verbose and nowrite
+ # commands.
+ #
+ module FileUtilsExt
+ include FileUtils
+
+ class << self
+ attr_accessor :verbose_flag, :nowrite_flag
+ end
+
+ DEFAULT = Object.new
+
+ FileUtilsExt.verbose_flag = DEFAULT
+ FileUtilsExt.nowrite_flag = false
+
+ FileUtils.commands.each do |name|
+ opts = FileUtils.options_of name
+ default_options = []
+ if opts.include?("verbose")
+ default_options << ":verbose => FileUtilsExt.verbose_flag"
+ end
+ if opts.include?("noop")
+ default_options << ":noop => FileUtilsExt.nowrite_flag"
+ end
+
+ next if default_options.empty?
+ module_eval(<<-EOS, __FILE__, __LINE__ + 1)
+ def #{name}( *args, &block )
+ super(
+ *rake_merge_option(args,
+ #{default_options.join(', ')}
+ ), &block)
+ end
+ EOS
+ end
+
+ # Get/set the verbose flag controlling output from the FileUtils
+ # utilities. If verbose is true, then the utility method is
+ # echoed to standard output.
+ #
+ # Examples:
+ # verbose # return the current value of the
+ # # verbose flag
+ # verbose(v) # set the verbose flag to _v_.
+ # verbose(v) { code } # Execute code with the verbose flag set
+ # # temporarily to _v_. Return to the
+ # # original value when code is done.
+ def verbose(value=nil)
+ oldvalue = FileUtilsExt.verbose_flag
+ FileUtilsExt.verbose_flag = value unless value.nil?
+ if block_given?
+ begin
+ yield
+ ensure
+ FileUtilsExt.verbose_flag = oldvalue
+ end
+ end
+ FileUtilsExt.verbose_flag
+ end
+
+ # Get/set the nowrite flag controlling output from the FileUtils
+ # utilities. If verbose is true, then the utility method is
+ # echoed to standard output.
+ #
+ # Examples:
+ # nowrite # return the current value of the
+ # # nowrite flag
+ # nowrite(v) # set the nowrite flag to _v_.
+ # nowrite(v) { code } # Execute code with the nowrite flag set
+ # # temporarily to _v_. Return to the
+ # # original value when code is done.
+ def nowrite(value=nil)
+ oldvalue = FileUtilsExt.nowrite_flag
+ FileUtilsExt.nowrite_flag = value unless value.nil?
+ if block_given?
+ begin
+ yield
+ ensure
+ FileUtilsExt.nowrite_flag = oldvalue
+ end
+ end
+ oldvalue
+ end
+
+ # Use this function to prevent potentially destructive ruby code
+ # from running when the :nowrite flag is set.
+ #
+ # Example:
+ #
+ # when_writing("Building Project") do
+ # project.build
+ # end
+ #
+ # The following code will build the project under normal
+ # conditions. If the nowrite(true) flag is set, then the example
+ # will print:
+ #
+ # DRYRUN: Building Project
+ #
+ # instead of actually building the project.
+ #
+ def when_writing(msg=nil)
+ if FileUtilsExt.nowrite_flag
+ $stderr.puts "DRYRUN: #{msg}" if msg
+ else
+ yield
+ end
+ end
+
+ # Merge the given options with the default values.
+ def rake_merge_option(args, defaults)
+ if Hash === args.last
+ defaults.update(args.last)
+ args.pop
+ end
+ args.push defaults
+ args
+ end
+
+ # Send the message to the default rake output (which is $stderr).
+ def rake_output_message(message)
+ $stderr.puts(message)
+ end
+
+ # Check that the options do not contain options not listed in
+ # +optdecl+. An ArgumentError exception is thrown if non-declared
+ # options are found.
+ def rake_check_options(options, *optdecl)
+ h = options.dup
+ optdecl.each do |name|
+ h.delete name
+ end
+ raise ArgumentError, "no such option: #{h.keys.join(' ')}" unless
+ h.empty?
+ end
+
+ extend self
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/invocation_chain.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/invocation_chain.rb
new file mode 100644
index 00000000..44a99549
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/invocation_chain.rb
@@ -0,0 +1,57 @@
+# frozen_string_literal: true
+module Rake
+
+ # InvocationChain tracks the chain of task invocations to detect
+ # circular dependencies.
+ class InvocationChain < LinkedList
+
+ # Is the invocation already in the chain?
+ def member?(invocation)
+ head == invocation || tail.member?(invocation)
+ end
+
+ # Append an invocation to the chain of invocations. It is an error
+ # if the invocation already listed.
+ def append(invocation)
+ if member?(invocation)
+ fail RuntimeError, "Circular dependency detected: #{to_s} => #{invocation}"
+ end
+ conj(invocation)
+ end
+
+ # Convert to string, ie: TOP => invocation => invocation
+ def to_s
+ "#{prefix}#{head}"
+ end
+
+ # Class level append.
+ def self.append(invocation, chain)
+ chain.append(invocation)
+ end
+
+ private
+
+ def prefix
+ "#{tail} => "
+ end
+
+ # Null object for an empty chain.
+ class EmptyInvocationChain < LinkedList::EmptyLinkedList
+ @parent = InvocationChain
+
+ def member?(obj)
+ false
+ end
+
+ def append(invocation)
+ conj(invocation)
+ end
+
+ def to_s
+ "TOP"
+ end
+ end
+
+ EMPTY = EmptyInvocationChain.new
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/invocation_exception_mixin.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/invocation_exception_mixin.rb
new file mode 100644
index 00000000..b0d307a4
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/invocation_exception_mixin.rb
@@ -0,0 +1,17 @@
+# frozen_string_literal: true
+module Rake
+ module InvocationExceptionMixin
+ # Return the invocation chain (list of Rake tasks) that were in
+ # effect when this exception was detected by rake. May be null if
+ # no tasks were active.
+ def chain
+ @rake_invocation_chain ||= nil
+ end
+
+ # Set the invocation chain in effect when this exception was
+ # detected.
+ def chain=(value)
+ @rake_invocation_chain = value
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/late_time.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/late_time.rb
new file mode 100644
index 00000000..8fe02494
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/late_time.rb
@@ -0,0 +1,18 @@
+# frozen_string_literal: true
+module Rake
+ # LateTime is a fake timestamp that occurs _after_ any other time value.
+ class LateTime
+ include Comparable
+ include Singleton
+
+ def <=>(other)
+ 1
+ end
+
+ def to_s
+ ""
+ end
+ end
+
+ LATE = LateTime.instance
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/linked_list.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/linked_list.rb
new file mode 100644
index 00000000..11fa46f0
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/linked_list.rb
@@ -0,0 +1,112 @@
+# frozen_string_literal: true
+module Rake
+
+ # Polylithic linked list structure used to implement several data
+ # structures in Rake.
+ class LinkedList
+ include Enumerable
+ attr_reader :head, :tail
+
+ # Polymorphically add a new element to the head of a list. The
+ # type of head node will be the same list type as the tail.
+ def conj(item)
+ self.class.cons(item, self)
+ end
+
+ # Is the list empty?
+ # .make guards against a list being empty making any instantiated LinkedList
+ # object not empty by default
+ # You should consider overriding this method if you implement your own .make method
+ def empty?
+ false
+ end
+
+ # Lists are structurally equivalent.
+ def ==(other)
+ current = self
+ while !current.empty? && !other.empty?
+ return false if current.head != other.head
+ current = current.tail
+ other = other.tail
+ end
+ current.empty? && other.empty?
+ end
+
+ # Convert to string: LL(item, item...)
+ def to_s
+ items = map(&:to_s).join(", ")
+ "LL(#{items})"
+ end
+
+ # Same as +to_s+, but with inspected items.
+ def inspect
+ items = map(&:inspect).join(", ")
+ "LL(#{items})"
+ end
+
+ # For each item in the list.
+ def each
+ current = self
+ while !current.empty?
+ yield(current.head)
+ current = current.tail
+ end
+ self
+ end
+
+ # Make a list out of the given arguments. This method is
+ # polymorphic
+ def self.make(*args)
+ # return an EmptyLinkedList if there are no arguments
+ return empty if !args || args.empty?
+
+ # build a LinkedList by starting at the tail and iterating
+ # through each argument
+ # inject takes an EmptyLinkedList to start
+ args.reverse.inject(empty) do |list, item|
+ list = cons(item, list)
+ list # return the newly created list for each item in the block
+ end
+ end
+
+ # Cons a new head onto the tail list.
+ def self.cons(head, tail)
+ new(head, tail)
+ end
+
+ # The standard empty list class for the given LinkedList class.
+ def self.empty
+ self::EMPTY
+ end
+
+ protected
+
+ def initialize(head, tail=EMPTY)
+ @head = head
+ @tail = tail
+ end
+
+ # Represent an empty list, using the Null Object Pattern.
+ #
+ # When inheriting from the LinkedList class, you should implement
+ # a type specific Empty class as well. Make sure you set the class
+ # instance variable @parent to the associated list class (this
+ # allows conj, cons and make to work polymorphically).
+ class EmptyLinkedList < LinkedList
+ @parent = LinkedList
+
+ def initialize
+ end
+
+ def empty?
+ true
+ end
+
+ def self.cons(head, tail)
+ @parent.cons(head, tail)
+ end
+ end
+
+ EMPTY = EmptyLinkedList.new
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/loaders/makefile.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/loaders/makefile.rb
new file mode 100644
index 00000000..46f4beaa
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/loaders/makefile.rb
@@ -0,0 +1,54 @@
+# frozen_string_literal: true
+module Rake
+
+ # Makefile loader to be used with the import file loader. Use this to
+ # import dependencies from make dependency tools:
+ #
+ # require 'rake/loaders/makefile'
+ #
+ # file ".depends.mf" => [SRC_LIST] do |t|
+ # sh "makedepend -f- -- #{CFLAGS} -- #{t.prerequisites} > #{t.name}"
+ # end
+ #
+ # import ".depends.mf"
+ #
+ # See {Importing Dependencies}[link:doc/rakefile_rdoc.html#label-Importing+Dependencies]
+ # for further details.
+
+ class MakefileLoader
+ include Rake::DSL
+
+ SPACE_MARK = "\0" # :nodoc:
+
+ # Load the makefile dependencies in +fn+.
+ def load(fn) # :nodoc:
+ lines = File.read fn
+ lines.gsub!(/\\ /, SPACE_MARK)
+ lines.gsub!(/#[^\n]*\n/m, "")
+ lines.gsub!(/\\\n/, " ")
+ lines.each_line do |line|
+ process_line(line)
+ end
+ end
+
+ private
+
+ # Process one logical line of makefile data.
+ def process_line(line) # :nodoc:
+ file_tasks, args = line.split(":", 2)
+ return if args.nil?
+ dependents = args.split.map { |d| respace(d) }
+ file_tasks.scan(/\S+/) do |file_task|
+ file_task = respace(file_task)
+ file file_task => dependents
+ end
+ end
+
+ def respace(str) # :nodoc:
+ str.tr SPACE_MARK, " "
+ end
+ end
+
+ # Install the handler
+ Rake.application.add_loader("mf", MakefileLoader.new)
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/multi_task.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/multi_task.rb
new file mode 100644
index 00000000..3ae363cb
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/multi_task.rb
@@ -0,0 +1,14 @@
+# frozen_string_literal: true
+module Rake
+
+ # Same as a regular task, but the immediate prerequisites are done in
+ # parallel using Ruby threads.
+ #
+ class MultiTask < Task
+ private
+
+ def invoke_prerequisites(task_args, invocation_chain) # :nodoc:
+ invoke_prerequisites_concurrently(task_args, invocation_chain)
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/name_space.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/name_space.rb
new file mode 100644
index 00000000..32f8139f
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/name_space.rb
@@ -0,0 +1,38 @@
+# frozen_string_literal: true
+##
+# The NameSpace class will lookup task names in the scope defined by a
+# +namespace+ command.
+
+class Rake::NameSpace
+
+ ##
+ # Create a namespace lookup object using the given task manager
+ # and the list of scopes.
+
+ def initialize(task_manager, scope_list)
+ @task_manager = task_manager
+ @scope = scope_list.dup
+ end
+
+ ##
+ # Lookup a task named +name+ in the namespace.
+
+ def [](name)
+ @task_manager.lookup(name, @scope)
+ end
+
+ ##
+ # The scope of the namespace (a LinkedList)
+
+ def scope
+ @scope.dup
+ end
+
+ ##
+ # Return the list of tasks defined in this and nested namespaces.
+
+ def tasks
+ @task_manager.tasks_in_scope(@scope)
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/packagetask.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/packagetask.rb
new file mode 100644
index 00000000..f65affa6
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/packagetask.rb
@@ -0,0 +1,211 @@
+# frozen_string_literal: true
+# Define a package task library to aid in the definition of
+# redistributable package files.
+
+require "rake"
+require "rake/tasklib"
+
+module Rake
+
+ # Create a packaging task that will package the project into
+ # distributable files (e.g zip archive or tar files).
+ #
+ # The PackageTask will create the following targets:
+ #
+ # +:package+ ::
+ # Create all the requested package files.
+ #
+ # +:clobber_package+ ::
+ # Delete all the package files. This target is automatically
+ # added to the main clobber target.
+ #
+ # +:repackage+ ::
+ # Rebuild the package files from scratch, even if they are not out
+ # of date.
+ #
+ # "package_dir/name-version.tgz" ::
+ # Create a gzipped tar package (if need_tar is true).
+ #
+ # "package_dir/name-version.tar.gz" ::
+ # Create a gzipped tar package (if need_tar_gz is true).
+ #
+ # "package_dir/name-version.tar.bz2" ::
+ # Create a bzip2'd tar package (if need_tar_bz2 is true).
+ #
+ # "package_dir/name-version.zip" ::
+ # Create a zip package archive (if need_zip is true).
+ #
+ # Example:
+ #
+ # Rake::PackageTask.new("rake", "1.2.3") do |p|
+ # p.need_tar = true
+ # p.package_files.include("lib/**/*.rb")
+ # end
+ #
+ class PackageTask < TaskLib
+ # Name of the package (from the GEM Spec).
+ attr_accessor :name
+
+ # Version of the package (e.g. '1.3.2').
+ attr_accessor :version
+
+ # Directory used to store the package files (default is 'pkg').
+ attr_accessor :package_dir
+
+ # True if a gzipped tar file (tgz) should be produced (default is
+ # false).
+ attr_accessor :need_tar
+
+ # True if a gzipped tar file (tar.gz) should be produced (default
+ # is false).
+ attr_accessor :need_tar_gz
+
+ # True if a bzip2'd tar file (tar.bz2) should be produced (default
+ # is false).
+ attr_accessor :need_tar_bz2
+
+ # True if a xz'd tar file (tar.xz) should be produced (default is false)
+ attr_accessor :need_tar_xz
+
+ # True if a zip file should be produced (default is false)
+ attr_accessor :need_zip
+
+ # List of files to be included in the package.
+ attr_accessor :package_files
+
+ # Tar command for gzipped or bzip2ed archives. The default is 'tar'.
+ attr_accessor :tar_command
+
+ # Zip command for zipped archives. The default is 'zip'.
+ attr_accessor :zip_command
+
+ # Create a Package Task with the given name and version. Use +:noversion+
+ # as the version to build a package without a version or to provide a
+ # fully-versioned package name.
+
+ def initialize(name=nil, version=nil)
+ init(name, version)
+ yield self if block_given?
+ define unless name.nil?
+ end
+
+ # Initialization that bypasses the "yield self" and "define" step.
+ def init(name, version)
+ @name = name
+ @version = version
+ @package_files = Rake::FileList.new
+ @package_dir = "pkg"
+ @need_tar = false
+ @need_tar_gz = false
+ @need_tar_bz2 = false
+ @need_tar_xz = false
+ @need_zip = false
+ @tar_command = "tar"
+ @zip_command = "zip"
+ end
+
+ # Create the tasks defined by this task library.
+ def define
+ fail "Version required (or :noversion)" if @version.nil?
+ @version = nil if :noversion == @version
+
+ desc "Build all the packages"
+ task :package
+
+ desc "Force a rebuild of the package files"
+ task repackage: [:clobber_package, :package]
+
+ desc "Remove package products"
+ task :clobber_package do
+ rm_r package_dir rescue nil
+ end
+
+ task clobber: [:clobber_package]
+
+ [
+ [need_tar, tgz_file, "z"],
+ [need_tar_gz, tar_gz_file, "z"],
+ [need_tar_bz2, tar_bz2_file, "j"],
+ [need_tar_xz, tar_xz_file, "J"]
+ ].each do |need, file, flag|
+ if need
+ task package: ["#{package_dir}/#{file}"]
+ file "#{package_dir}/#{file}" =>
+ [package_dir_path] + package_files do
+ chdir(package_dir) do
+ sh @tar_command, "#{flag}cvf", file, package_name
+ end
+ end
+ end
+ end
+
+ if need_zip
+ task package: ["#{package_dir}/#{zip_file}"]
+ file "#{package_dir}/#{zip_file}" =>
+ [package_dir_path] + package_files do
+ chdir(package_dir) do
+ sh @zip_command, "-r", zip_file, package_name
+ end
+ end
+ end
+
+ directory package_dir_path => @package_files do
+ @package_files.each do |fn|
+ f = File.join(package_dir_path, fn)
+ fdir = File.dirname(f)
+ mkdir_p(fdir) unless File.exist?(fdir)
+ if File.directory?(fn)
+ mkdir_p(f)
+ else
+ rm_f f
+ safe_ln(fn, f)
+ end
+ end
+ end
+ self
+ end
+
+ # The name of this package
+
+ def package_name
+ @version ? "#{@name}-#{@version}" : @name
+ end
+
+ # The directory this package will be built in
+
+ def package_dir_path
+ "#{package_dir}/#{package_name}"
+ end
+
+ # The package name with .tgz added
+
+ def tgz_file
+ "#{package_name}.tgz"
+ end
+
+ # The package name with .tar.gz added
+
+ def tar_gz_file
+ "#{package_name}.tar.gz"
+ end
+
+ # The package name with .tar.bz2 added
+
+ def tar_bz2_file
+ "#{package_name}.tar.bz2"
+ end
+
+ # The package name with .tar.xz added
+
+ def tar_xz_file
+ "#{package_name}.tar.xz"
+ end
+
+ # The package name with .zip added
+
+ def zip_file
+ "#{package_name}.zip"
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/phony.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/phony.rb
new file mode 100644
index 00000000..8caa5de1
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/phony.rb
@@ -0,0 +1,16 @@
+# frozen_string_literal: true
+# Defines a :phony task that you can use as a dependency. This allows
+# file-based tasks to use non-file-based tasks as prerequisites
+# without forcing them to rebuild.
+#
+# See FileTask#out_of_date? and Task#timestamp for more info.
+
+require "rake"
+
+task :phony
+
+Rake::Task[:phony].tap do |task|
+ def task.timestamp # :nodoc:
+ Time.at 0
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/private_reader.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/private_reader.rb
new file mode 100644
index 00000000..2815ce64
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/private_reader.rb
@@ -0,0 +1,21 @@
+# frozen_string_literal: true
+module Rake
+
+ # Include PrivateReader to use +private_reader+.
+ module PrivateReader # :nodoc: all
+
+ def self.included(base)
+ base.extend(ClassMethods)
+ end
+
+ module ClassMethods
+
+ # Declare a list of private accessors
+ def private_reader(*names)
+ attr_reader(*names)
+ private(*names)
+ end
+ end
+
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/promise.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/promise.rb
new file mode 100644
index 00000000..ecff4321
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/promise.rb
@@ -0,0 +1,100 @@
+# frozen_string_literal: true
+module Rake
+
+ # A Promise object represents a promise to do work (a chore) in the
+ # future. The promise is created with a block and a list of
+ # arguments for the block. Calling value will return the value of
+ # the promised chore.
+ #
+ # Used by ThreadPool.
+ #
+ class Promise # :nodoc: all
+ NOT_SET = Object.new.freeze # :nodoc:
+
+ attr_accessor :recorder
+
+ # Create a promise to do the chore specified by the block.
+ def initialize(args, &block)
+ @mutex = Mutex.new
+ @result = NOT_SET
+ @error = NOT_SET
+ @args = args
+ @block = block
+ end
+
+ # Return the value of this promise.
+ #
+ # If the promised chore is not yet complete, then do the work
+ # synchronously. We will wait.
+ def value
+ unless complete?
+ stat :sleeping_on, item_id: object_id
+ @mutex.synchronize do
+ stat :has_lock_on, item_id: object_id
+ chore
+ stat :releasing_lock_on, item_id: object_id
+ end
+ end
+ error? ? raise(@error) : @result
+ end
+
+ # If no one else is working this promise, go ahead and do the chore.
+ def work
+ stat :attempting_lock_on, item_id: object_id
+ if @mutex.try_lock
+ stat :has_lock_on, item_id: object_id
+ chore
+ stat :releasing_lock_on, item_id: object_id
+ @mutex.unlock
+ else
+ stat :bailed_on, item_id: object_id
+ end
+ end
+
+ private
+
+ # Perform the chore promised
+ def chore
+ if complete?
+ stat :found_completed, item_id: object_id
+ return
+ end
+ stat :will_execute, item_id: object_id
+ begin
+ @result = @block.call(*@args)
+ rescue Exception => e
+ @error = e
+ end
+ stat :did_execute, item_id: object_id
+ discard
+ end
+
+ # Do we have a result for the promise
+ def result?
+ ! @result.equal?(NOT_SET)
+ end
+
+ # Did the promise throw an error
+ def error?
+ ! @error.equal?(NOT_SET)
+ end
+
+ # Are we done with the promise
+ def complete?
+ result? || error?
+ end
+
+ # free up these items for the GC
+ def discard
+ @args = nil
+ @block = nil
+ end
+
+ # Record execution statistics if there is a recorder
+ def stat(*args)
+ @recorder.call(*args) if @recorder
+ end
+
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/pseudo_status.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/pseudo_status.rb
new file mode 100644
index 00000000..8b3c9894
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/pseudo_status.rb
@@ -0,0 +1,30 @@
+# frozen_string_literal: true
+module Rake
+
+ ##
+ # Exit status class for times the system just gives us a nil.
+ class PseudoStatus # :nodoc: all
+ attr_reader :exitstatus
+
+ def initialize(code=0)
+ @exitstatus = code
+ end
+
+ def to_i
+ @exitstatus << 8
+ end
+
+ def >>(n)
+ to_i >> n
+ end
+
+ def stopped?
+ false
+ end
+
+ def exited?
+ true
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rake_module.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rake_module.rb
new file mode 100644
index 00000000..03c29562
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rake_module.rb
@@ -0,0 +1,67 @@
+# frozen_string_literal: true
+require "rake/application"
+
+module Rake
+
+ class << self
+ # Current Rake Application
+ def application
+ @application ||= Rake::Application.new
+ end
+
+ # Set the current Rake application object.
+ def application=(app)
+ @application = app
+ end
+
+ def suggested_thread_count # :nodoc:
+ @cpu_count ||= Rake::CpuCounter.count
+ @cpu_count + 4
+ end
+
+ # Return the original directory where the Rake application was started.
+ def original_dir
+ application.original_dir
+ end
+
+ # Load a rakefile.
+ def load_rakefile(path)
+ load(path)
+ end
+
+ # Add files to the rakelib list
+ def add_rakelib(*files)
+ application.options.rakelib ||= []
+ application.options.rakelib.concat(files)
+ end
+
+ # Make +block_application+ the default rake application inside a block so
+ # you can load rakefiles into a different application.
+ #
+ # This is useful when you want to run rake tasks inside a library without
+ # running rake in a sub-shell.
+ #
+ # Example:
+ #
+ # Dir.chdir 'other/directory'
+ #
+ # other_rake = Rake.with_application do |rake|
+ # rake.load_rakefile
+ # end
+ #
+ # puts other_rake.tasks
+
+ def with_application(block_application = Rake::Application.new)
+ orig_application = Rake.application
+
+ Rake.application = block_application
+
+ yield block_application
+
+ block_application
+ ensure
+ Rake.application = orig_application
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rake_test_loader.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rake_test_loader.rb
new file mode 100644
index 00000000..f0f7772b
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rake_test_loader.rb
@@ -0,0 +1,27 @@
+# frozen_string_literal: true
+require "rake"
+
+# Load the test files from the command line.
+argv = ARGV.select do |argument|
+ begin
+ case argument
+ when /^-/ then
+ argument
+ when /\*/ then
+ FileList[argument].to_a.each do |file|
+ require File.expand_path file
+ end
+
+ false
+ else
+ require File.expand_path argument
+
+ false
+ end
+ rescue LoadError => e
+ raise unless e.path
+ abort "\nFile does not exist: #{e.path}\n\n"
+ end
+end
+
+ARGV.replace argv
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rule_recursion_overflow_error.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rule_recursion_overflow_error.rb
new file mode 100644
index 00000000..a51e7748
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/rule_recursion_overflow_error.rb
@@ -0,0 +1,20 @@
+# frozen_string_literal: true
+module Rake
+
+ # Error indicating a recursion overflow error in task selection.
+ class RuleRecursionOverflowError < StandardError
+ def initialize(*args)
+ super
+ @targets = []
+ end
+
+ def add_target(target)
+ @targets << target
+ end
+
+ def message
+ super + ": [" + @targets.reverse.join(" => ") + "]"
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/scope.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/scope.rb
new file mode 100644
index 00000000..27c05da8
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/scope.rb
@@ -0,0 +1,43 @@
+# frozen_string_literal: true
+module Rake
+ class Scope < LinkedList # :nodoc: all
+
+ # Path for the scope.
+ def path
+ map(&:to_s).reverse.join(":")
+ end
+
+ # Path for the scope + the named path.
+ def path_with_task_name(task_name)
+ "#{path}:#{task_name}"
+ end
+
+ # Trim +n+ innermost scope levels from the scope. In no case will
+ # this trim beyond the toplevel scope.
+ def trim(n)
+ result = self
+ while n > 0 && ! result.empty?
+ result = result.tail
+ n -= 1
+ end
+ result
+ end
+
+ # Scope lists always end with an EmptyScope object. See Null
+ # Object Pattern)
+ class EmptyScope < EmptyLinkedList
+ @parent = Scope
+
+ def path
+ ""
+ end
+
+ def path_with_task_name(task_name)
+ task_name
+ end
+ end
+
+ # Singleton null object for an empty scope.
+ EMPTY = EmptyScope.new
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task.rb
new file mode 100644
index 00000000..c7e0a1d9
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task.rb
@@ -0,0 +1,411 @@
+# frozen_string_literal: true
+require "rake/invocation_exception_mixin"
+
+module Rake
+
+ ##
+ # A Task is the basic unit of work in a Rakefile. Tasks have associated
+ # actions (possibly more than one) and a list of prerequisites. When
+ # invoked, a task will first ensure that all of its prerequisites have an
+ # opportunity to run and then it will execute its own actions.
+ #
+ # Tasks are not usually created directly using the new method, but rather
+ # use the +file+ and +task+ convenience methods.
+ #
+ class Task
+ # List of prerequisites for a task.
+ attr_reader :prerequisites
+
+ # List of actions attached to a task.
+ attr_reader :actions
+
+ # Application owning this task.
+ attr_accessor :application
+
+ # Array of nested namespaces names used for task lookup by this task.
+ attr_reader :scope
+
+ # File/Line locations of each of the task definitions for this
+ # task (only valid if the task was defined with the detect
+ # location option set).
+ attr_reader :locations
+
+ # Has this task already been invoked? Already invoked tasks
+ # will be skipped unless you reenable them.
+ attr_reader :already_invoked
+
+ # Return task name
+ def to_s
+ name
+ end
+
+ def inspect # :nodoc:
+ "<#{self.class} #{name} => [#{prerequisites.join(', ')}]>"
+ end
+
+ # List of sources for task.
+ attr_writer :sources
+ def sources
+ if defined?(@sources)
+ @sources
+ else
+ prerequisites
+ end
+ end
+
+ # List of prerequisite tasks
+ def prerequisite_tasks
+ prerequisites.map { |pre| lookup_prerequisite(pre) }
+ end
+
+ def lookup_prerequisite(prerequisite_name) # :nodoc:
+ scoped_prerequisite_task = application[prerequisite_name, @scope]
+ if scoped_prerequisite_task == self
+ unscoped_prerequisite_task = application[prerequisite_name]
+ end
+ unscoped_prerequisite_task || scoped_prerequisite_task
+ end
+ private :lookup_prerequisite
+
+ # List of all unique prerequisite tasks including prerequisite tasks'
+ # prerequisites.
+ # Includes self when cyclic dependencies are found.
+ def all_prerequisite_tasks
+ seen = {}
+ collect_prerequisites(seen)
+ seen.values
+ end
+
+ def collect_prerequisites(seen) # :nodoc:
+ prerequisite_tasks.each do |pre|
+ next if seen[pre.name]
+ seen[pre.name] = pre
+ pre.collect_prerequisites(seen)
+ end
+ end
+ protected :collect_prerequisites
+
+ # First source from a rule (nil if no sources)
+ def source
+ sources.first
+ end
+
+ # Create a task named +task_name+ with no actions or prerequisites. Use
+ # +enhance+ to add actions and prerequisites.
+ def initialize(task_name, app)
+ @name = task_name.to_s
+ @prerequisites = []
+ @actions = []
+ @already_invoked = false
+ @comments = []
+ @lock = Monitor.new
+ @application = app
+ @scope = app.current_scope
+ @arg_names = nil
+ @locations = []
+ @invocation_exception = nil
+ end
+
+ # Enhance a task with prerequisites or actions. Returns self.
+ def enhance(deps=nil, &block)
+ @prerequisites |= deps if deps
+ @actions << block if block_given?
+ self
+ end
+
+ # Name of the task, including any namespace qualifiers.
+ def name
+ @name.to_s
+ end
+
+ # Name of task with argument list description.
+ def name_with_args # :nodoc:
+ if arg_description
+ "#{name}#{arg_description}"
+ else
+ name
+ end
+ end
+
+ # Argument description (nil if none).
+ def arg_description # :nodoc:
+ @arg_names ? "[#{arg_names.join(',')}]" : nil
+ end
+
+ # Name of arguments for this task.
+ def arg_names
+ @arg_names || []
+ end
+
+ # Reenable the task, allowing its tasks to be executed if the task
+ # is invoked again.
+ def reenable
+ @already_invoked = false
+ end
+
+ # Clear the existing prerequisites, actions, comments, and arguments of a rake task.
+ def clear
+ clear_prerequisites
+ clear_actions
+ clear_comments
+ clear_args
+ self
+ end
+
+ # Clear the existing prerequisites of a rake task.
+ def clear_prerequisites
+ prerequisites.clear
+ self
+ end
+
+ # Clear the existing actions on a rake task.
+ def clear_actions
+ actions.clear
+ self
+ end
+
+ # Clear the existing comments on a rake task.
+ def clear_comments
+ @comments = []
+ self
+ end
+
+ # Clear the existing arguments on a rake task.
+ def clear_args
+ @arg_names = nil
+ self
+ end
+
+ # Invoke the task if it is needed. Prerequisites are invoked first.
+ def invoke(*args)
+ task_args = TaskArguments.new(arg_names, args)
+ invoke_with_call_chain(task_args, InvocationChain::EMPTY)
+ end
+
+ # Same as invoke, but explicitly pass a call chain to detect
+ # circular dependencies.
+ #
+ # If multiple tasks depend on this
+ # one in parallel, they will all fail if the first execution of
+ # this task fails.
+ def invoke_with_call_chain(task_args, invocation_chain)
+ new_chain = Rake::InvocationChain.append(self, invocation_chain)
+ @lock.synchronize do
+ begin
+ if application.options.trace
+ application.trace "** Invoke #{name} #{format_trace_flags}"
+ end
+
+ if @already_invoked
+ if @invocation_exception
+ if application.options.trace
+ application.trace "** Previous invocation of #{name} failed #{format_trace_flags}"
+ end
+ raise @invocation_exception
+ else
+ return
+ end
+ end
+
+ @already_invoked = true
+
+ invoke_prerequisites(task_args, new_chain)
+ execute(task_args) if needed?
+ rescue Exception => ex
+ add_chain_to(ex, new_chain)
+ @invocation_exception = ex
+ raise ex
+ end
+ end
+ end
+ protected :invoke_with_call_chain
+
+ def add_chain_to(exception, new_chain) # :nodoc:
+ exception.extend(InvocationExceptionMixin) unless
+ exception.respond_to?(:chain)
+ exception.chain = new_chain if exception.chain.nil?
+ end
+ private :add_chain_to
+
+ # Invoke all the prerequisites of a task.
+ def invoke_prerequisites(task_args, invocation_chain) # :nodoc:
+ if application.options.always_multitask
+ invoke_prerequisites_concurrently(task_args, invocation_chain)
+ else
+ prerequisite_tasks.each { |p|
+ prereq_args = task_args.new_scope(p.arg_names)
+ p.invoke_with_call_chain(prereq_args, invocation_chain)
+ }
+ end
+ end
+
+ # Invoke all the prerequisites of a task in parallel.
+ def invoke_prerequisites_concurrently(task_args, invocation_chain)# :nodoc:
+ futures = prerequisite_tasks.map do |p|
+ prereq_args = task_args.new_scope(p.arg_names)
+ application.thread_pool.future(p) do |r|
+ r.invoke_with_call_chain(prereq_args, invocation_chain)
+ end
+ end
+ futures.each(&:value)
+ end
+
+ # Format the trace flags for display.
+ def format_trace_flags
+ flags = []
+ flags << "first_time" unless @already_invoked
+ flags << "not_needed" unless needed?
+ flags.empty? ? "" : "(" + flags.join(", ") + ")"
+ end
+ private :format_trace_flags
+
+ # Execute the actions associated with this task.
+ def execute(args=nil)
+ args ||= EMPTY_TASK_ARGS
+ if application.options.dryrun
+ application.trace "** Execute (dry run) #{name}"
+ return
+ end
+ application.trace "** Execute #{name}" if application.options.trace
+ application.enhance_with_matching_rule(name) if @actions.empty?
+ @actions.each { |act| act.call(self, args) }
+ end
+
+ # Is this task needed?
+ def needed?
+ true
+ end
+
+ # Timestamp for this task. Basic tasks return the current time for their
+ # time stamp. Other tasks can be more sophisticated.
+ def timestamp
+ Time.now
+ end
+
+ # Add a description to the task. The description can consist of an option
+ # argument list (enclosed brackets) and an optional comment.
+ def add_description(description)
+ return unless description
+ comment = description.strip
+ add_comment(comment) if comment && ! comment.empty?
+ end
+
+ def comment=(comment) # :nodoc:
+ add_comment(comment)
+ end
+
+ def add_comment(comment) # :nodoc:
+ return if comment.nil?
+ @comments << comment unless @comments.include?(comment)
+ end
+ private :add_comment
+
+ # Full collection of comments. Multiple comments are separated by
+ # newlines.
+ def full_comment
+ transform_comments("\n")
+ end
+
+ # First line (or sentence) of all comments. Multiple comments are
+ # separated by a "/".
+ def comment
+ transform_comments(" / ") { |c| first_sentence(c) }
+ end
+
+ # Transform the list of comments as specified by the block and
+ # join with the separator.
+ def transform_comments(separator, &block)
+ if @comments.empty?
+ nil
+ else
+ block ||= lambda { |c| c }
+ @comments.map(&block).join(separator)
+ end
+ end
+ private :transform_comments
+
+ # Get the first sentence in a string. The sentence is terminated
+ # by the first period, exclamation mark, or the end of the line.
+ # Decimal points do not count as periods.
+ def first_sentence(string)
+ string.split(/(?<=\w)(\.|!)[ \t]|(\.$|!)|\n/).first
+ end
+ private :first_sentence
+
+ # Set the names of the arguments for this task. +args+ should be
+ # an array of symbols, one for each argument name.
+ def set_arg_names(args)
+ @arg_names = args.map(&:to_sym)
+ end
+
+ # Return a string describing the internal state of a task. Useful for
+ # debugging.
+ def investigation
+ result = "------------------------------\n".dup
+ result << "Investigating #{name}\n"
+ result << "class: #{self.class}\n"
+ result << "task needed: #{needed?}\n"
+ result << "timestamp: #{timestamp}\n"
+ result << "pre-requisites: \n"
+ prereqs = prerequisite_tasks
+ prereqs.sort! { |a, b| a.timestamp <=> b.timestamp }
+ prereqs.each do |p|
+ result << "--#{p.name} (#{p.timestamp})\n"
+ end
+ latest_prereq = prerequisite_tasks.map(&:timestamp).max
+ result << "latest-prerequisite time: #{latest_prereq}\n"
+ result << "................................\n\n"
+ return result
+ end
+
+ # ----------------------------------------------------------------
+ # Rake Module Methods
+ #
+ class << self
+
+ # Clear the task list. This cause rake to immediately forget all the
+ # tasks that have been assigned. (Normally used in the unit tests.)
+ def clear
+ Rake.application.clear
+ end
+
+ # List of all defined tasks.
+ def tasks
+ Rake.application.tasks
+ end
+
+ # Return a task with the given name. If the task is not currently
+ # known, try to synthesize one from the defined rules. If no rules are
+ # found, but an existing file matches the task name, assume it is a file
+ # task with no dependencies or actions.
+ def [](task_name)
+ Rake.application[task_name]
+ end
+
+ # TRUE if the task name is already defined.
+ def task_defined?(task_name)
+ Rake.application.lookup(task_name) != nil
+ end
+
+ # Define a task given +args+ and an option block. If a rule with the
+ # given name already exists, the prerequisites and actions are added to
+ # the existing task. Returns the defined task.
+ def define_task(*args, &block)
+ Rake.application.define_task(self, *args, &block)
+ end
+
+ # Define a rule for synthesizing tasks.
+ def create_rule(*args, &block)
+ Rake.application.create_rule(*args, &block)
+ end
+
+ # Apply the scope to the task name according to the rules for
+ # this kind of task. Generic tasks will accept the scope as
+ # part of the name.
+ def scope_name(scope, task_name)
+ scope.path_with_task_name(task_name)
+ end
+
+ end # class << Rake::Task
+ end # class Rake::Task
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_argument_error.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_argument_error.rb
new file mode 100644
index 00000000..ef20076c
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_argument_error.rb
@@ -0,0 +1,8 @@
+# frozen_string_literal: true
+module Rake
+
+ # Error indicating an ill-formed task declaration.
+ class TaskArgumentError < ArgumentError
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_arguments.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_arguments.rb
new file mode 100644
index 00000000..0d3001af
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_arguments.rb
@@ -0,0 +1,109 @@
+# frozen_string_literal: true
+module Rake
+
+ ##
+ # TaskArguments manage the arguments passed to a task.
+ #
+ class TaskArguments
+ include Enumerable
+
+ # Argument names
+ attr_reader :names
+
+ # Create a TaskArgument object with a list of argument +names+ and a set
+ # of associated +values+. +parent+ is the parent argument object.
+ def initialize(names, values, parent=nil)
+ @names = names
+ @parent = parent
+ @hash = {}
+ @values = values
+ names.each_with_index { |name, i|
+ next if values[i].nil? || values[i] == ""
+ @hash[name.to_sym] = values[i]
+ }
+ end
+
+ # Retrieve the complete array of sequential values
+ def to_a
+ @values.dup
+ end
+
+ # Retrieve the list of values not associated with named arguments
+ def extras
+ @values[@names.length..-1] || []
+ end
+
+ # Create a new argument scope using the prerequisite argument
+ # names.
+ def new_scope(names)
+ values = names.map { |n| self[n] }
+ self.class.new(names, values + extras, self)
+ end
+
+ # Find an argument value by name or index.
+ def [](index)
+ lookup(index.to_sym)
+ end
+
+ # Specify a hash of default values for task arguments. Use the
+ # defaults only if there is no specific value for the given
+ # argument.
+ def with_defaults(defaults)
+ @hash = defaults.merge(@hash)
+ end
+
+ # Enumerates the arguments and their values
+ def each(&block)
+ @hash.each(&block)
+ end
+
+ # Extracts the argument values at +keys+
+ def values_at(*keys)
+ keys.map { |k| lookup(k) }
+ end
+
+ # Returns the value of the given argument via method_missing
+ def method_missing(sym, *args)
+ lookup(sym.to_sym)
+ end
+
+ # Returns a Hash of arguments and their values
+ def to_hash
+ @hash.dup
+ end
+
+ def to_s # :nodoc:
+ inspect
+ end
+
+ def inspect # :nodoc:
+ inspection = @hash.map do |k,v|
+ "#{k.to_s}: #{v.to_s}"
+ end.join(", ")
+
+ "#<#{self.class} #{inspection}>"
+ end
+
+ # Returns true if +key+ is one of the arguments
+ def has_key?(key)
+ @hash.has_key?(key)
+ end
+ alias key? has_key?
+
+ def fetch(*args, &block)
+ @hash.fetch(*args, &block)
+ end
+
+ protected
+
+ def lookup(name) # :nodoc:
+ if @hash.has_key?(name)
+ @hash[name]
+ elsif @parent
+ @parent.lookup(name)
+ end
+ end
+ end
+
+ EMPTY_TASK_ARGS = TaskArguments.new([], []) # :nodoc:
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_manager.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_manager.rb
new file mode 100644
index 00000000..c1e60b95
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/task_manager.rb
@@ -0,0 +1,323 @@
+# frozen_string_literal: true
+module Rake
+
+ # The TaskManager module is a mixin for managing tasks.
+ module TaskManager
+ # Track the last comment made in the Rakefile.
+ attr_accessor :last_description
+
+ def initialize # :nodoc:
+ super
+ @tasks = Hash.new
+ @rules = Array.new
+ @scope = Scope.make
+ @last_description = nil
+ end
+
+ def create_rule(*args, &block) # :nodoc:
+ pattern, args, deps = resolve_args(args)
+ pattern = Regexp.new(Regexp.quote(pattern) + "$") if String === pattern
+ @rules << [pattern, args, deps, block]
+ end
+
+ def define_task(task_class, *args, &block) # :nodoc:
+ task_name, arg_names, deps = resolve_args(args)
+
+ original_scope = @scope
+ if String === task_name and
+ not task_class.ancestors.include? Rake::FileTask
+ task_name, *definition_scope = *(task_name.split(":").reverse)
+ @scope = Scope.make(*(definition_scope + @scope.to_a))
+ end
+
+ task_name = task_class.scope_name(@scope, task_name)
+ deps = [deps] unless deps.respond_to?(:to_ary)
+ deps = deps.map { |d| Rake.from_pathname(d).to_s }
+ task = intern(task_class, task_name)
+ task.set_arg_names(arg_names) unless arg_names.empty?
+ if Rake::TaskManager.record_task_metadata
+ add_location(task)
+ task.add_description(get_description(task))
+ end
+ task.enhance(deps, &block)
+ ensure
+ @scope = original_scope
+ end
+
+ # Lookup a task. Return an existing task if found, otherwise
+ # create a task of the current type.
+ def intern(task_class, task_name)
+ @tasks[task_name.to_s] ||= task_class.new(task_name, self)
+ end
+
+ # Find a matching task for +task_name+.
+ def [](task_name, scopes=nil)
+ task_name = task_name.to_s
+ self.lookup(task_name, scopes) or
+ enhance_with_matching_rule(task_name) or
+ synthesize_file_task(task_name) or
+ fail generate_message_for_undefined_task(task_name)
+ end
+
+ def generate_message_for_undefined_task(task_name)
+ message = "Don't know how to build task '#{task_name}' (see --tasks)"
+ message + generate_did_you_mean_suggestions(task_name)
+ end
+
+ def generate_did_you_mean_suggestions(task_name)
+ return "" unless defined?(::DidYouMean::SpellChecker)
+
+ suggestions = ::DidYouMean::SpellChecker.new(dictionary: @tasks.keys).correct(task_name.to_s)
+ if ::DidYouMean.respond_to?(:formatter)# did_you_mean v1.2.0 or later
+ ::DidYouMean.formatter.message_for(suggestions)
+ elsif defined?(::DidYouMean::Formatter) # before did_you_mean v1.2.0
+ ::DidYouMean::Formatter.new(suggestions).to_s
+ else
+ ""
+ end
+ end
+
+ def synthesize_file_task(task_name) # :nodoc:
+ return nil unless File.exist?(task_name)
+ define_task(Rake::FileTask, task_name)
+ end
+
+ # Resolve the arguments for a task/rule. Returns a triplet of
+ # [task_name, arg_name_list, prerequisites].
+ def resolve_args(args)
+ if args.last.is_a?(Hash)
+ deps = args.pop
+ resolve_args_with_dependencies(args, deps)
+ else
+ resolve_args_without_dependencies(args)
+ end
+ end
+
+ # Resolve task arguments for a task or rule when there are no
+ # dependencies declared.
+ #
+ # The patterns recognized by this argument resolving function are:
+ #
+ # task :t
+ # task :t, [:a]
+ #
+ def resolve_args_without_dependencies(args)
+ task_name = args.shift
+ if args.size == 1 && args.first.respond_to?(:to_ary)
+ arg_names = args.first.to_ary
+ else
+ arg_names = args
+ end
+ [task_name, arg_names, []]
+ end
+ private :resolve_args_without_dependencies
+
+ # Resolve task arguments for a task or rule when there are
+ # dependencies declared.
+ #
+ # The patterns recognized by this argument resolving function are:
+ #
+ # task :t => [:d]
+ # task :t, [a] => [:d]
+ #
+ def resolve_args_with_dependencies(args, hash) # :nodoc:
+ fail "Task Argument Error" if hash.size != 1
+ key, value = hash.map { |k, v| [k, v] }.first
+ if args.empty?
+ task_name = key
+ arg_names = []
+ deps = value || []
+ else
+ task_name = args.shift
+ arg_names = key
+ deps = value
+ end
+ deps = [deps] unless deps.respond_to?(:to_ary)
+ [task_name, arg_names, deps]
+ end
+ private :resolve_args_with_dependencies
+
+ # If a rule can be found that matches the task name, enhance the
+ # task with the prerequisites and actions from the rule. Set the
+ # source attribute of the task appropriately for the rule. Return
+ # the enhanced task or nil of no rule was found.
+ def enhance_with_matching_rule(task_name, level=0)
+ fail Rake::RuleRecursionOverflowError,
+ "Rule Recursion Too Deep" if level >= 16
+ @rules.each do |pattern, args, extensions, block|
+ if pattern && pattern.match(task_name)
+ task = attempt_rule(task_name, pattern, args, extensions, block, level)
+ return task if task
+ end
+ end
+ nil
+ rescue Rake::RuleRecursionOverflowError => ex
+ ex.add_target(task_name)
+ fail ex
+ end
+
+ # List of all defined tasks in this application.
+ def tasks
+ @tasks.values.sort_by { |t| t.name }
+ end
+
+ # List of all the tasks defined in the given scope (and its
+ # sub-scopes).
+ def tasks_in_scope(scope)
+ prefix = scope.path
+ tasks.select { |t|
+ /^#{prefix}:/ =~ t.name
+ }
+ end
+
+ # Clear all tasks in this application.
+ def clear
+ @tasks.clear
+ @rules.clear
+ end
+
+ # Lookup a task, using scope and the scope hints in the task name.
+ # This method performs straight lookups without trying to
+ # synthesize file tasks or rules. Special scope names (e.g. '^')
+ # are recognized. If no scope argument is supplied, use the
+ # current scope. Return nil if the task cannot be found.
+ def lookup(task_name, initial_scope=nil)
+ initial_scope ||= @scope
+ task_name = task_name.to_s
+ if task_name =~ /^rake:/
+ scopes = Scope.make
+ task_name = task_name.sub(/^rake:/, "")
+ elsif task_name =~ /^(\^+)/
+ scopes = initial_scope.trim($1.size)
+ task_name = task_name.sub(/^(\^+)/, "")
+ else
+ scopes = initial_scope
+ end
+ lookup_in_scope(task_name, scopes)
+ end
+
+ # Lookup the task name
+ def lookup_in_scope(name, scope)
+ loop do
+ tn = scope.path_with_task_name(name)
+ task = @tasks[tn]
+ return task if task
+ break if scope.empty?
+ scope = scope.tail
+ end
+ nil
+ end
+ private :lookup_in_scope
+
+ # Return the list of scope names currently active in the task
+ # manager.
+ def current_scope
+ @scope
+ end
+
+ # Evaluate the block in a nested namespace named +name+. Create
+ # an anonymous namespace if +name+ is nil.
+ def in_namespace(name)
+ name ||= generate_name
+ @scope = Scope.new(name, @scope)
+ ns = NameSpace.new(self, @scope)
+ yield(ns)
+ ns
+ ensure
+ @scope = @scope.tail
+ end
+
+ private
+
+ # Add a location to the locations field of the given task.
+ def add_location(task)
+ loc = find_location
+ task.locations << loc if loc
+ task
+ end
+
+ # Find the location that called into the dsl layer.
+ def find_location
+ locations = caller
+ i = 0
+ while locations[i]
+ return locations[i + 1] if locations[i] =~ /rake\/dsl_definition.rb/
+ i += 1
+ end
+ nil
+ end
+
+ # Generate an anonymous namespace name.
+ def generate_name
+ @seed ||= 0
+ @seed += 1
+ "_anon_#{@seed}"
+ end
+
+ def trace_rule(level, message) # :nodoc:
+ options.trace_output.puts "#{" " * level}#{message}" if
+ Rake.application.options.trace_rules
+ end
+
+ # Attempt to create a rule given the list of prerequisites.
+ def attempt_rule(task_name, task_pattern, args, extensions, block, level)
+ sources = make_sources(task_name, task_pattern, extensions)
+ prereqs = sources.map { |source|
+ trace_rule level, "Attempting Rule #{task_name} => #{source}"
+ if File.exist?(source) || Rake::Task.task_defined?(source)
+ trace_rule level, "(#{task_name} => #{source} ... EXIST)"
+ source
+ elsif parent = enhance_with_matching_rule(source, level + 1)
+ trace_rule level, "(#{task_name} => #{source} ... ENHANCE)"
+ parent.name
+ else
+ trace_rule level, "(#{task_name} => #{source} ... FAIL)"
+ return nil
+ end
+ }
+ task = FileTask.define_task(task_name, { args => prereqs }, &block)
+ task.sources = prereqs
+ task
+ end
+
+ # Make a list of sources from the list of file name extensions /
+ # translation procs.
+ def make_sources(task_name, task_pattern, extensions)
+ result = extensions.map { |ext|
+ case ext
+ when /%/
+ task_name.pathmap(ext)
+ when %r{/}
+ ext
+ when /^\./
+ source = task_name.sub(task_pattern, ext)
+ source == ext ? task_name.ext(ext) : source
+ when String
+ ext
+ when Proc, Method
+ if ext.arity == 1
+ ext.call(task_name)
+ else
+ ext.call
+ end
+ else
+ fail "Don't know how to handle rule dependent: #{ext.inspect}"
+ end
+ }
+ result.flatten
+ end
+
+ # Return the current description, clearing it in the process.
+ def get_description(task)
+ desc = @last_description
+ @last_description = nil
+ desc
+ end
+
+ class << self
+ attr_accessor :record_task_metadata # :nodoc:
+ TaskManager.record_task_metadata = false
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/tasklib.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/tasklib.rb
new file mode 100644
index 00000000..5354b4f9
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/tasklib.rb
@@ -0,0 +1,12 @@
+# frozen_string_literal: true
+require "rake"
+
+module Rake
+
+ # Base class for Task Libraries.
+ class TaskLib
+ include Cloneable
+ include Rake::DSL
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/testtask.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/testtask.rb
new file mode 100644
index 00000000..53762756
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/testtask.rb
@@ -0,0 +1,224 @@
+# frozen_string_literal: true
+require "rake"
+require "rake/tasklib"
+
+module Rake
+
+ # Create a task that runs a set of tests.
+ #
+ # Example:
+ # require "rake/testtask"
+ #
+ # Rake::TestTask.new do |t|
+ # t.libs << "test"
+ # t.test_files = FileList['test/test*.rb']
+ # t.verbose = true
+ # end
+ #
+ # If rake is invoked with a "TEST=filename" command line option,
+ # then the list of test files will be overridden to include only the
+ # filename specified on the command line. This provides an easy way
+ # to run just one test.
+ #
+ # If rake is invoked with a "TESTOPTS=options" command line option,
+ # then the given options are passed to the test process after a
+ # '--'. This allows Test::Unit options to be passed to the test
+ # suite.
+ #
+ # Examples:
+ #
+ # rake test # run tests normally
+ # rake test TEST=just_one_file.rb # run just one test file.
+ # rake test TESTOPTS="-v" # run in verbose mode
+ # rake test TESTOPTS="--runner=fox" # use the fox test runner
+ #
+ class TestTask < TaskLib
+
+ # Name of test task. (default is :test)
+ attr_accessor :name
+
+ # List of directories added to $LOAD_PATH before running the
+ # tests. (default is 'lib')
+ attr_accessor :libs
+
+ # True if verbose test output desired. (default is false)
+ attr_accessor :verbose
+
+ # Test options passed to the test suite. An explicit
+ # TESTOPTS=opts on the command line will override this. (default
+ # is NONE)
+ attr_accessor :options
+
+ # Request that the tests be run with the warning flag set.
+ # E.g. warning=true implies "ruby -w" used to run the tests.
+ # (default is true)
+ attr_accessor :warning
+
+ # Glob pattern to match test files. (default is 'test/test*.rb')
+ attr_accessor :pattern
+
+ # Style of test loader to use. Options are:
+ #
+ # * :rake -- Rake provided test loading script (default).
+ # * :testrb -- Ruby provided test loading script.
+ # * :direct -- Load tests using command line loader.
+ #
+ attr_accessor :loader
+
+ # Array of command line options to pass to ruby when running test loader.
+ attr_accessor :ruby_opts
+
+ # Description of the test task. (default is 'Run tests')
+ attr_accessor :description
+
+ # Task prerequisites.
+ attr_accessor :deps
+
+ # Explicitly define the list of test files to be included in a
+ # test. +list+ is expected to be an array of file names (a
+ # FileList is acceptable). If both +pattern+ and +test_files+ are
+ # used, then the list of test files is the union of the two.
+ def test_files=(list)
+ @test_files = list
+ end
+
+ # Create a testing task.
+ def initialize(name=:test)
+ @name = name
+ @libs = ["lib"]
+ @pattern = nil
+ @options = nil
+ @test_files = nil
+ @verbose = false
+ @warning = true
+ @loader = :rake
+ @ruby_opts = []
+ @description = "Run tests" + (@name == :test ? "" : " for #{@name}")
+ @deps = []
+ if @name.is_a?(Hash)
+ @deps = @name.values.first
+ @name = @name.keys.first
+ end
+ yield self if block_given?
+ @pattern = "test/test*.rb" if @pattern.nil? && @test_files.nil?
+ define
+ end
+
+ # Create the tasks defined by this task lib.
+ def define
+ desc @description
+ task @name => Array(deps) do
+ FileUtilsExt.verbose(@verbose) do
+ puts "Use TESTOPTS=\"--verbose\" to pass --verbose" \
+ ", etc. to runners." if ARGV.include? "--verbose"
+ args =
+ "#{ruby_opts_string} #{run_code} " +
+ "#{file_list_string} #{option_list}"
+ ruby args do |ok, status|
+ if !ok && status.respond_to?(:signaled?) && status.signaled?
+ raise SignalException.new(status.termsig)
+ elsif !ok
+ status = "Command failed with status (#{status.exitstatus})"
+ details = ": [ruby #{args}]"
+ message =
+ if Rake.application.options.trace or @verbose
+ status + details
+ else
+ status
+ end
+
+ fail message
+ end
+ end
+ end
+ end
+ self
+ end
+
+ def option_list # :nodoc:
+ (ENV["TESTOPTS"] ||
+ ENV["TESTOPT"] ||
+ ENV["TEST_OPTS"] ||
+ ENV["TEST_OPT"] ||
+ @options ||
+ "")
+ end
+
+ def ruby_opts_string # :nodoc:
+ opts = @ruby_opts.dup
+ opts.unshift("-I\"#{lib_path}\"") unless @libs.empty?
+ opts.unshift("-w") if @warning
+ opts.join(" ")
+ end
+
+ def lib_path # :nodoc:
+ @libs.join(File::PATH_SEPARATOR)
+ end
+
+ def file_list_string # :nodoc:
+ file_list.map { |fn| "\"#{fn}\"" }.join(" ")
+ end
+
+ def file_list # :nodoc:
+ if ENV["TEST"]
+ FileList[ENV["TEST"]]
+ else
+ result = []
+ result += @test_files.to_a if @test_files
+ result += FileList[@pattern].to_a if @pattern
+ result
+ end
+ end
+
+ def ruby_version # :nodoc:
+ RUBY_VERSION
+ end
+
+ def run_code # :nodoc:
+ case @loader
+ when :direct
+ "-e \"ARGV.each{|f| require f}\""
+ when :testrb
+ "-S testrb"
+ when :rake
+ "#{rake_include_arg} \"#{rake_loader}\""
+ end
+ end
+
+ def rake_loader # :nodoc:
+ find_file("rake/rake_test_loader") or
+ fail "unable to find rake test loader"
+ end
+
+ def find_file(fn) # :nodoc:
+ $LOAD_PATH.each do |path|
+ file_path = File.join(path, "#{fn}.rb")
+ return file_path if File.exist? file_path
+ end
+ nil
+ end
+
+ def rake_include_arg # :nodoc:
+ spec = Gem.loaded_specs["rake"]
+ if spec.respond_to?(:default_gem?) && spec.default_gem?
+ ""
+ else
+ "-I\"#{rake_lib_dir}\""
+ end
+ end
+
+ def rake_lib_dir # :nodoc:
+ find_dir("rake") or
+ fail "unable to find rake lib"
+ end
+
+ def find_dir(fn) # :nodoc:
+ $LOAD_PATH.each do |path|
+ file_path = File.join(path, "#{fn}.rb")
+ return path if File.exist? file_path
+ end
+ nil
+ end
+
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/thread_history_display.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/thread_history_display.rb
new file mode 100644
index 00000000..412ea37b
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/thread_history_display.rb
@@ -0,0 +1,49 @@
+# frozen_string_literal: true
+require "rake/private_reader"
+
+module Rake
+
+ class ThreadHistoryDisplay # :nodoc: all
+ include Rake::PrivateReader
+
+ private_reader :stats, :items, :threads
+
+ def initialize(stats)
+ @stats = stats
+ @items = { _seq_: 1 }
+ @threads = { _seq_: "A" }
+ end
+
+ def show
+ puts "Job History:"
+ stats.each do |stat|
+ stat[:data] ||= {}
+ rename(stat, :thread, threads)
+ rename(stat[:data], :item_id, items)
+ rename(stat[:data], :new_thread, threads)
+ rename(stat[:data], :deleted_thread, threads)
+ printf("%8d %2s %-20s %s\n",
+ (stat[:time] * 1_000_000).round,
+ stat[:thread],
+ stat[:event],
+ stat[:data].map do |k, v| "#{k}:#{v}" end.join(" "))
+ end
+ end
+
+ private
+
+ def rename(hash, key, renames)
+ if hash && hash[key]
+ original = hash[key]
+ value = renames[original]
+ unless value
+ value = renames[:_seq_]
+ renames[:_seq_] = renames[:_seq_].succ
+ renames[original] = value
+ end
+ hash[key] = value
+ end
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/thread_pool.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/thread_pool.rb
new file mode 100644
index 00000000..b01a5efe
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/thread_pool.rb
@@ -0,0 +1,163 @@
+# frozen_string_literal: true
+require "set"
+
+require "rake/promise"
+
+module Rake
+
+ class ThreadPool # :nodoc: all
+
+ # Creates a ThreadPool object. The +thread_count+ parameter is the size
+ # of the pool.
+ def initialize(thread_count)
+ @max_active_threads = [thread_count, 0].max
+ @threads = Set.new
+ @threads_mon = Monitor.new
+ @queue = Queue.new
+ @join_cond = @threads_mon.new_cond
+
+ @history_start_time = nil
+ @history = []
+ @history_mon = Monitor.new
+ @total_threads_in_play = 0
+ end
+
+ # Creates a future executed by the +ThreadPool+.
+ #
+ # The args are passed to the block when executing (similarly to
+ # Thread#new) The return value is an object representing
+ # a future which has been created and added to the queue in the
+ # pool. Sending #value to the object will sleep the
+ # current thread until the future is finished and will return the
+ # result (or raise an exception thrown from the future)
+ def future(*args, &block)
+ promise = Promise.new(args, &block)
+ promise.recorder = lambda { |*stats| stat(*stats) }
+
+ @queue.enq promise
+ stat :queued, item_id: promise.object_id
+ start_thread
+ promise
+ end
+
+ # Waits until the queue of futures is empty and all threads have exited.
+ def join
+ @threads_mon.synchronize do
+ begin
+ stat :joining
+ @join_cond.wait unless @threads.empty?
+ stat :joined
+ rescue Exception => e
+ stat :joined
+ $stderr.puts e
+ $stderr.print "Queue contains #{@queue.size} items. " +
+ "Thread pool contains #{@threads.count} threads\n"
+ $stderr.print "Current Thread #{Thread.current} status = " +
+ "#{Thread.current.status}\n"
+ $stderr.puts e.backtrace.join("\n")
+ @threads.each do |t|
+ $stderr.print "Thread #{t} status = #{t.status}\n"
+ $stderr.puts t.backtrace.join("\n")
+ end
+ raise e
+ end
+ end
+ end
+
+ # Enable the gathering of history events.
+ def gather_history #:nodoc:
+ @history_start_time = Time.now if @history_start_time.nil?
+ end
+
+ # Return a array of history events for the thread pool.
+ #
+ # History gathering must be enabled to be able to see the events
+ # (see #gather_history). Best to call this when the job is
+ # complete (i.e. after ThreadPool#join is called).
+ def history # :nodoc:
+ @history_mon.synchronize { @history.dup }.
+ sort_by { |i| i[:time] }.
+ each { |i| i[:time] -= @history_start_time }
+ end
+
+ # Return a hash of always collected statistics for the thread pool.
+ def statistics # :nodoc:
+ {
+ total_threads_in_play: @total_threads_in_play,
+ max_active_threads: @max_active_threads,
+ }
+ end
+
+ private
+
+ # processes one item on the queue. Returns true if there was an
+ # item to process, false if there was no item
+ def process_queue_item #:nodoc:
+ return false if @queue.empty?
+
+ # Even though we just asked if the queue was empty, it
+ # still could have had an item which by this statement
+ # is now gone. For this reason we pass true to Queue#deq
+ # because we will sleep indefinitely if it is empty.
+ promise = @queue.deq(true)
+ stat :dequeued, item_id: promise.object_id
+ promise.work
+ return true
+
+ rescue ThreadError # this means the queue is empty
+ false
+ end
+
+ def safe_thread_count
+ @threads_mon.synchronize do
+ @threads.count
+ end
+ end
+
+ def start_thread # :nodoc:
+ @threads_mon.synchronize do
+ next unless @threads.count < @max_active_threads
+
+ t = Thread.new do
+ begin
+ while safe_thread_count <= @max_active_threads
+ break unless process_queue_item
+ end
+ ensure
+ @threads_mon.synchronize do
+ @threads.delete Thread.current
+ stat :ended, thread_count: @threads.count
+ @join_cond.broadcast if @threads.empty?
+ end
+ end
+ end
+
+ @threads << t
+ stat(
+ :spawned,
+ new_thread: t.object_id,
+ thread_count: @threads.count)
+ @total_threads_in_play = @threads.count if
+ @threads.count > @total_threads_in_play
+ end
+ end
+
+ def stat(event, data=nil) # :nodoc:
+ return if @history_start_time.nil?
+ info = {
+ event: event,
+ data: data,
+ time: Time.now,
+ thread: Thread.current.object_id,
+ }
+ @history_mon.synchronize { @history << info }
+ end
+
+ # for testing only
+
+ def __queue__ # :nodoc:
+ @queue
+ end
+ end
+
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/trace_output.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/trace_output.rb
new file mode 100644
index 00000000..d713a092
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/trace_output.rb
@@ -0,0 +1,23 @@
+# frozen_string_literal: true
+module Rake
+ module TraceOutput # :nodoc: all
+
+ # Write trace output to output stream +out+.
+ #
+ # The write is done as a single IO call (to print) to lessen the
+ # chance that the trace output is interrupted by other tasks also
+ # producing output.
+ def trace_on(out, *strings)
+ sep = $\ || "\n"
+ if strings.empty?
+ output = sep
+ else
+ output = strings.map { |s|
+ next if s.nil?
+ s.end_with?(sep) ? s : s + sep
+ }.join
+ end
+ out.print(output)
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/version.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/version.rb
new file mode 100644
index 00000000..2d66a8f7
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/version.rb
@@ -0,0 +1,10 @@
+# frozen_string_literal: true
+module Rake
+ VERSION = "12.3.1"
+
+ module Version # :nodoc: all
+ MAJOR, MINOR, BUILD, *OTHER = Rake::VERSION.split "."
+
+ NUMBERS = [MAJOR, MINOR, BUILD, *OTHER]
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/win32.rb b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/win32.rb
new file mode 100644
index 00000000..6e620318
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/lib/rake/win32.rb
@@ -0,0 +1,51 @@
+# frozen_string_literal: true
+require "rbconfig"
+
+module Rake
+ # Win 32 interface methods for Rake. Windows specific functionality
+ # will be placed here to collect that knowledge in one spot.
+ module Win32 # :nodoc: all
+
+ # Error indicating a problem in locating the home directory on a
+ # Win32 system.
+ class Win32HomeError < RuntimeError
+ end
+
+ class << self
+ # True if running on a windows system.
+ def windows?
+ RbConfig::CONFIG["host_os"] =~ %r!(msdos|mswin|djgpp|mingw|[Ww]indows)!
+ end
+
+ # The standard directory containing system wide rake files on
+ # Win 32 systems. Try the following environment variables (in
+ # order):
+ #
+ # * HOME
+ # * HOMEDRIVE + HOMEPATH
+ # * APPDATA
+ # * USERPROFILE
+ #
+ # If the above are not defined, the return nil.
+ def win32_system_dir #:nodoc:
+ win32_shared_path = ENV["HOME"]
+ if win32_shared_path.nil? && ENV["HOMEDRIVE"] && ENV["HOMEPATH"]
+ win32_shared_path = ENV["HOMEDRIVE"] + ENV["HOMEPATH"]
+ end
+
+ win32_shared_path ||= ENV["APPDATA"]
+ win32_shared_path ||= ENV["USERPROFILE"]
+ raise Win32HomeError,
+ "Unable to determine home path environment variable." if
+ win32_shared_path.nil? or win32_shared_path.empty?
+ normalize(File.join(win32_shared_path, "Rake"))
+ end
+
+ # Normalize a win32 path so that the slashes are all forward slashes.
+ def normalize(path)
+ path.gsub(/\\/, "/")
+ end
+
+ end
+ end
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/rake.gemspec b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/rake.gemspec
new file mode 100644
index 00000000..ddc9f2a6
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/gems/rake-12.3.1/rake.gemspec
@@ -0,0 +1,42 @@
+# frozen_string_literal: true
+$LOAD_PATH.unshift File.expand_path('../lib', __FILE__)
+require 'rake/version'
+
+Gem::Specification.new do |s|
+ s.name = "rake".freeze
+ s.version = Rake::VERSION
+ s.authors = ["Hiroshi SHIBATA".freeze, "Eric Hodel".freeze, "Jim Weirich".freeze]
+ s.email = ["hsbt@ruby-lang.org".freeze, "drbrain@segment7.net".freeze, "".freeze]
+
+ s.summary = "Rake is a Make-like program implemented in Ruby".freeze
+ s.description = <<-DESCRIPTION
+Rake is a Make-like program implemented in Ruby. Tasks and dependencies are
+specified in standard Ruby syntax.
+Rake has the following features:
+ * Rakefiles (rake's version of Makefiles) are completely defined in standard Ruby syntax.
+ No XML files to edit. No quirky Makefile syntax to worry about (is that a tab or a space?)
+ * Users can specify tasks with prerequisites.
+ * Rake supports rule patterns to synthesize implicit tasks.
+ * Flexible FileLists that act like arrays but know about manipulating file names and paths.
+ * Supports parallel execution of tasks.
+ DESCRIPTION
+ s.homepage = "https://github.com/ruby/rake".freeze
+ s.licenses = ["MIT".freeze]
+
+ s.files = %x[git ls-files -z].split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) } -
+ %w[.rubocop.yml .travis.yml appveyor.yml]
+ s.bindir = "exe"
+ s.executables = s.files.grep(%r{^exe/}) { |f| File.basename(f) }
+ s.require_paths = ["lib".freeze]
+
+ s.required_ruby_version = Gem::Requirement.new(">= 2.0.0".freeze)
+ s.rubygems_version = "2.6.1".freeze
+ s.required_rubygems_version = Gem::Requirement.new(">= 1.3.2".freeze)
+ s.rdoc_options = ["--main".freeze, "README.rdoc".freeze]
+
+ s.add_development_dependency(%q.freeze)
+ s.add_development_dependency(%q.freeze)
+ s.add_development_dependency(%q.freeze)
+ s.add_development_dependency(%q.freeze)
+ s.add_development_dependency(%q.freeze)
+end
diff --git a/spec/sample_bundler/vendor/bundle/jruby/2.3.0/specifications/rake-12.3.1.gemspec b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/specifications/rake-12.3.1.gemspec
new file mode 100644
index 00000000..22645302
--- /dev/null
+++ b/spec/sample_bundler/vendor/bundle/jruby/2.3.0/specifications/rake-12.3.1.gemspec
@@ -0,0 +1,49 @@
+# -*- encoding: utf-8 -*-
+# stub: rake 12.3.1 ruby lib
+
+Gem::Specification.new do |s|
+ s.name = "rake".freeze
+ s.version = "12.3.1"
+
+ s.required_rubygems_version = Gem::Requirement.new(">= 1.3.2".freeze) if s.respond_to? :required_rubygems_version=
+ s.require_paths = ["lib".freeze]
+ s.authors = ["Hiroshi SHIBATA".freeze, "Eric Hodel".freeze, "Jim Weirich".freeze]
+ s.bindir = "exe".freeze
+ s.date = "2018-03-22"
+ s.description = "Rake is a Make-like program implemented in Ruby. Tasks and dependencies are\nspecified in standard Ruby syntax.\nRake has the following features:\n * Rakefiles (rake's version of Makefiles) are completely defined in standard Ruby syntax.\n No XML files to edit. No quirky Makefile syntax to worry about (is that a tab or a space?)\n * Users can specify tasks with prerequisites.\n * Rake supports rule patterns to synthesize implicit tasks.\n * Flexible FileLists that act like arrays but know about manipulating file names and paths.\n * Supports parallel execution of tasks.\n".freeze
+ s.email = ["hsbt@ruby-lang.org".freeze, "drbrain@segment7.net".freeze, "".freeze]
+ s.executables = ["rake".freeze]
+ s.files = ["exe/rake".freeze]
+ s.homepage = "https://github.com/ruby/rake".freeze
+ s.licenses = ["MIT".freeze]
+ s.rdoc_options = ["--main".freeze, "README.rdoc".freeze]
+ s.required_ruby_version = Gem::Requirement.new(">= 2.0.0".freeze)
+ s.rubygems_version = "2.6.13".freeze
+ s.summary = "Rake is a Make-like program implemented in Ruby".freeze
+
+ s.installed_by_version = "2.6.13" if s.respond_to? :installed_by_version
+
+ if s.respond_to? :specification_version then
+ s.specification_version = 4
+
+ if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
+ s.add_development_dependency(%q.freeze, [">= 0"])
+ s.add_development_dependency(%q.freeze, [">= 0"])
+ s.add_development_dependency(%q.freeze, [">= 0"])
+ s.add_development_dependency(%q.freeze, [">= 0"])
+ s.add_development_dependency(%q.freeze, [">= 0"])
+ else
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ end
+ else
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ s.add_dependency(%q.freeze, [">= 0"])
+ end
+end
diff --git a/spec/warbler/bundler_spec.rb b/spec/warbler/bundler_spec.rb
index 68b55517..9c5d55ab 100644
--- a/spec/warbler/bundler_spec.rb
+++ b/spec/warbler/bundler_spec.rb
@@ -160,7 +160,7 @@ def bundle_install(*args)
file_list(%r{^bundler/gems/tester[^/]*/tester.gemspec}).should_not be_empty
jar.add_init_file(config)
contents = jar.contents('META-INF/init.rb')
- contents.should =~ /ENV\['BUNDLE_GEMFILE'\] = File.expand_path(.*, __FILE__)/
+ contents.should =~ /ENV\['BUNDLE_GEMFILE'\] ||= File.expand_path(.*, __FILE__)/
end
end
@@ -168,7 +168,7 @@ def bundle_install(*args)
File.open("Gemfile", "w") {|f| f << "source 'http://rubygems.org/'" }
jar.add_init_file(config)
contents = jar.contents('META-INF/init.rb')
- contents.should =~ /ENV\['BUNDLE_GEMFILE'\] = File.expand_path(.*, __FILE__)/
+ contents.should =~ /ENV\['BUNDLE_GEMFILE'\] ||= File.expand_path(.*, __FILE__)/
end
end
@@ -194,15 +194,18 @@ def bundle_install(*args)
end
context "with the runnable feature" do
+ let(:bundle_gemfile) { nil }
+
before do
File.open("Rakefile", "w") do |f|
f << <<-RUBY
task :test_task do
- puts "success"
+ puts Rake::VERSION
end
RUBY
end
+ ENV['BUNDLE_GEMFILE'] = bundle_gemfile if bundle_gemfile
use_config do |config|
config.features = %w{runnable}
end
@@ -221,10 +224,24 @@ def bundle_install(*args)
it "can run commands in the generated warfile" do
jar.create('foo.war')
+ ENV['BUNDLE_GEMFILE'] = nil
stdin, stdout, stderr, wait_thr = Open3.popen3('java -jar foo.war -S rake test_task')
wait_thr.value.success?.should be(true)
stderr.readlines.join.should eq("")
- stdout.readlines.join.should eq("success\n")
+ stdout.readlines.join.should eq("10.5.0\n")
+ end
+
+ context "with a custom Gemfile" do
+ let(:bundle_gemfile) { 'Special-Gemfile' }
+
+ it "uses the correct gems" do
+ jar.create('foo.war')
+ ENV['BUNDLE_GEMFILE'] = nil
+ stdin, stdout, stderr, wait_thr = Open3.popen3('java -jar foo.war -S rake test_task')
+ wait_thr.value.success?.should be(true)
+ stderr.readlines.join.should eq("")
+ stdout.readlines.join.should eq("12.3.1\n")
+ end
end
end
end