[前][次][番号順一覧][スレッド一覧]

ruby-changes:47876

From: hsbt <ko1@a...>
Date: Sun, 24 Sep 2017 03:27:23 +0900 (JST)
Subject: [ruby-changes:47876] hsbt:r59997 (trunk): removed bin/bundle_ruby, It was ignored upstream gemspec.

hsbt	2017-09-23 13:37:58 +0900 (Sat, 23 Sep 2017)

  New Revision: 59997

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=59997

  Log:
    removed bin/bundle_ruby, It was ignored upstream gemspec.
    
      * spec/bundler/other/*: Marked exclude tags for ruby repository.

  Removed files:
    trunk/bin/bundle_ruby
  Modified files:
    trunk/spec/bundler/other/bundle_ruby_spec.rb
    trunk/spec/bundler/other/major_deprecation_spec.rb
Index: bin/bundle_ruby
===================================================================
--- bin/bundle_ruby	(revision 59996)
+++ bin/bundle_ruby	(nonexistent)
@@ -1,59 +0,0 @@ https://github.com/ruby/ruby/blob/trunk/bin/bundle_ruby#L0
-#!/usr/bin/env ruby
-# frozen_string_literal: true
-
-Signal.trap("INT") { exit 1 }
-
-require "bundler/errors"
-require "bundler/ruby_version"
-require "bundler/ruby_dsl"
-require "bundler/shared_helpers"
-
-module Bundler
-  class Dsl
-    include RubyDsl
-
-    attr_accessor :ruby_version
-
-    def initialize
-      @ruby_version = nil
-    end
-
-    def eval_gemfile(gemfile, contents = nil)
-      contents ||= File.open(gemfile, "rb", &:read)
-      instance_eval(contents, gemfile.to_s, 1)
-    rescue SyntaxError => e
-      bt = e.message.split("\n")[1..-1]
-      raise GemfileError, ["Gemfile syntax error:", *bt].join("\n")
-    rescue ScriptError, RegexpError, NameError, ArgumentError => e
-      e.backtrace[0] = "#{e.backtrace[0]}: #{e.message} (#{e.class})"
-      STDERR.puts e.backtrace.join("\n       ")
-      raise GemfileError, "There was an error in your Gemfile," \
-        " and Bundler cannot continue."
-    end
-
-    def source(source, options = {})
-    end
-
-    def gem(name, *args)
-    end
-
-    def group(*args)
-    end
-  end
-end
-
-Bundler::SharedHelpers.major_deprecation("the bundle_ruby executable has been removed in favor of `bundle platform --ruby`")
-
-dsl = Bundler::Dsl.new
-begin
-  dsl.eval_gemfile(Bundler::SharedHelpers.default_gemfile)
-  ruby_version = dsl.ruby_version
-  if ruby_version
-    puts ruby_version
-  else
-    puts "No ruby version specified"
-  end
-rescue Bundler::GemfileError => e
-  puts e.message
-  exit(-1)
-end

Property changes on: bin/bundle_ruby
___________________________________________________________________
Deleted: svn:eol-style
## -1 +0,0 ##
-LF
\ No newline at end of property
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: spec/bundler/other/major_deprecation_spec.rb
===================================================================
--- spec/bundler/other/major_deprecation_spec.rb	(revision 59996)
+++ spec/bundler/other/major_deprecation_spec.rb	(revision 59997)
@@ -30,7 +30,7 @@ RSpec.describe "major deprecations" do https://github.com/ruby/ruby/blob/trunk/spec/bundler/other/major_deprecation_spec.rb#L30
     G
   end
 
-  describe "bundle_ruby" do
+  describe "bundle_ruby", :ruby_repo do
     it "prints a deprecation" do
       bundle_ruby
       out.gsub! "\nruby #{RUBY_VERSION}", ""
Index: spec/bundler/other/bundle_ruby_spec.rb
===================================================================
--- spec/bundler/other/bundle_ruby_spec.rb	(revision 59996)
+++ spec/bundler/other/bundle_ruby_spec.rb	(revision 59997)
@@ -1,7 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/spec/bundler/other/bundle_ruby_spec.rb#L1
 # frozen_string_literal: true
 require "spec_helper"
 
-RSpec.describe "bundle_ruby" do
+RSpec.describe "bundle_ruby", :ruby_repo do
   context "without patchlevel" do
     it "returns the ruby version" do
       gemfile <<-G

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]