summaryrefslogtreecommitdiff
path: root/lib/bundler/cli/gem.rb
diff options
context:
space:
mode:
authorEric Mueller <nevinera@gmail.com>2023-11-29 22:40:10 -0500
committergit <svn-admin@ruby-lang.org>2023-12-01 17:52:38 +0000
commit73440e1ef21e1dd7ca590e402d37b835b9b1f0bb (patch)
tree7757e2c5e22bde407cb90fded3ca17465eddb176 /lib/bundler/cli/gem.rb
parent079dfa1812e0f23a74c86e271245504b069b4c17 (diff)
[rubygems/rubygems] Many major_deprecations supply :removed_message
Generally the removed message is very similar, but often it needs to specify that the feature has "been removed" instead of "will be removed", or "been deprecated". And a few chunks of text needed more substantial updates. And a number of them seemed to have been carefully crafted to make sense in either context, so I left those alone. https://github.com/rubygems/rubygems/commit/8d42cf9104
Diffstat (limited to 'lib/bundler/cli/gem.rb')
-rw-r--r--lib/bundler/cli/gem.rb11
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/bundler/cli/gem.rb b/lib/bundler/cli/gem.rb
index fb064ed702..aef45d19e1 100644
--- a/lib/bundler/cli/gem.rb
+++ b/lib/bundler/cli/gem.rb
@@ -380,15 +380,20 @@ module Bundler
def deprecated_rubocop_option
if !options[:rubocop].nil?
if options[:rubocop]
- Bundler::SharedHelpers.major_deprecation 2, "--rubocop is deprecated, use --linter=rubocop"
+ Bundler::SharedHelpers.major_deprecation 2,
+ "--rubocop is deprecated, use --linter=rubocop",
+ :removed_message => "--rubocop has been removed, use --linter=rubocop"
"rubocop"
else
- Bundler::SharedHelpers.major_deprecation 2, "--no-rubocop is deprecated, use --linter"
+ Bundler::SharedHelpers.major_deprecation 2,
+ "--no-rubocop is deprecated, use --linter",
+ :removed_message => "--no-rubocop has been removed, use --linter"
false
end
elsif !Bundler.settings["gem.rubocop"].nil?
Bundler::SharedHelpers.major_deprecation 2,
- "config gem.rubocop is deprecated; we've updated your config to use gem.linter instead"
+ "config gem.rubocop is deprecated; we've updated your config to use gem.linter instead",
+ :removed_message => "config gem.rubocop has been removed; we've updated your config to use gem.linter instead"
Bundler.settings["gem.rubocop"] ? "rubocop" : false
end
end