"requiring version.rb" strategy has some issues.
- cannot work when cross-compiling
- often introduces wrong namespace
- must know the superclasses
- costs at each runtime than at build-time
etc.
https://github.com/ruby/actions/runs/500526558?check_suite_focus=true#step:16:127
```
Failures:
1) Bundler.setup when Bundler is bundled doesn't blow up
Failure/Error: expect(err).to be_empty
expected `"fatal: not a git repository (or any of the parent directories): .git\nfatal: not a git repository (o...the parent directories): .git\nfatal: not a git repository (or any of the parent directories): .git".empty?` to return true, got false
Commands:
$ /home/runner/work/actions/actions/snapshot-master/ruby \
-I/home/runner/work/actions/actions/snapshot-master/lib:/home/runner/work/actions/actions/snapshot-master/spec/bundler \
-rsupport/hax -rsupport/artifice/fail \
/home/runner/work/actions/actions/snapshot-master/libexec/bundle install --retry 0
Resolving dependencies...
Using bundler 2.1.4
Bundle complete! 1 Gemfile dependency, 1 gem now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
# $? => 0
$ /home/runner/work/actions/actions/snapshot-master/ruby \
-I/home/runner/work/actions/actions/snapshot-master/lib:/home/runner/work/actions/actions/snapshot-master/spec/bundler \
-rsupport/hax -rsupport/artifice/fail \
/home/runner/work/actions/actions/snapshot-master/libexec/bundle exec ruby -e \
require\ \'bundler\'\;\ Bundler.setup
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
# $? => 0
# ./spec/bundler/runtime/setup_spec.rb:1056:in `block (3 levels) in <top (required)>'
# ./spec/bundler/spec_helper.rb:111:in `block (3 levels) in <top (required)>'
# ./spec/bundler/spec_helper.rb:111:in `block (2 levels) in <top (required)>'
# ./spec/bundler/spec_helper.rb:78:in `block (2 levels) in <top (required)>'
make: *** [yes-test-bundler] Error 1
```
This removes the related tests, and puts the related specs behind
version guards. This affects all code in lib, including some
libraries that may want to support older versions of Ruby.
* lib/cgi/util.rb: reverted r65505. require_relative does not
work for cgi/escape.so, as extension libraries are placed in
other directories than ruby libraries. [Bug #15206]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65511 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
If uplevel keyword is given, the warning message is prepended
with caller file and line information and the string "warning: ".
The use of the uplevel keyword makes Kernel#warn format output
similar to how rb_warn formats output.
This patch modifies net/ftp and net/imap to use Kernel#warn
instead of $stderr.puts or $stderr.printf, since they are used
for printing warnings.
This makes lib/cgi/core and tempfile use $stderr.puts instead of
warn for debug logging, since they are used for debug printing
and not for warning.
This does not modify bundler, rubygems, or rdoc, as those are
maintained outside of ruby and probably wish to remain backwards
compatible with older ruby versions.
rb_warn_m code is originally from nobu, but I've changed it
so that it only includes the path and lineno from uplevel
(not the method), and also prepends the string "warning: ",
to make it more similar to rb_warn.
From: Jeremy Evans code@jeremyevans.net
Signed-off-by: Urabe Shyouhei shyouhei@ruby-lang.org
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
to make it compatible with ERB::Util.url_encode.
ext/cgi/escape/escape.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/cgi/{core,util}.rb: include CGI::Util not only extending, to
share `@@accept_charset` class variable, so that it is always
accessible. [ruby-core:80986] [Bug #13539]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58576 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/cgi/escape/escape.c (cgiesc_unescape): define unescape
method instead of _unescape, and should pass the optional
argument to the super method.
* lib/cgi/util.rb (CGI::Util#_unescape): remove intermediate
method.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54655 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
When you change this to true, you may need to add more tests.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/cgi/session.rb (create_new_id): use SHA512 instead of MD5.
pointed out by SARWAR JAHAN.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51748 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/cgi/cookie.rb (CGI::Cookie#secure): revert part of r50496,
which is irrelevant to GH-887, as the document states that the
argument must be a boolean.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50497 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
it may be set before the body.
Reported by ko1 and mrkn. [ruby-core:59088] [Bug #9247]
* lib/cgi/core.rb: Ditto.
* lib/drb/ssl.rb: Ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44184 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
thank you @bbxiao1 via
https://github.com/ruby/ruby/pull/333
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41431 b2dd03c8-39d4-4d8f-98ff-823fe69b080e