summaryrefslogtreecommitdiff
path: root/lib/rubygems
diff options
context:
space:
mode:
authorJeremy Evans <code@jeremyevans.net>2019-04-07 16:44:49 -0700
committerJeremy Evans <code@jeremyevans.net>2019-08-30 12:39:31 -0700
commitd08e1004e0ee1286e4513de2a170391a4d0a0116 (patch)
tree5c7dd8244c2bf4c0f9b06725f3585c7ffc710ef3 /lib/rubygems
parent3f67fcd3d5ca5e2907790eb5bb16d03f5884ece8 (diff)
downloadruby-d08e1004e0ee1286e4513de2a170391a4d0a0116.tar.gz
Fix keyword argument separation issues in lib
Mostly requires adding ** in either calls or method definitions.
Diffstat (limited to 'lib/rubygems')
-rw-r--r--lib/rubygems/commands/setup_command.rb2
-rw-r--r--lib/rubygems/package.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/rubygems/commands/setup_command.rb b/lib/rubygems/commands/setup_command.rb
index 1cbc980eb0..3448fdfb4e 100644
--- a/lib/rubygems/commands/setup_command.rb
+++ b/lib/rubygems/commands/setup_command.rb
@@ -129,7 +129,7 @@ By default, this RubyGems will install gem as:
end
module MakeDirs
- def mkdir_p(path, *opts)
+ def mkdir_p(path, **opts)
super
(@mkdirs ||= []) << path
end
diff --git a/lib/rubygems/package.rb b/lib/rubygems/package.rb
index 06b1dc0db3..b5f83205b3 100644
--- a/lib/rubygems/package.rb
+++ b/lib/rubygems/package.rb
@@ -513,7 +513,7 @@ EOM
path = File.expand_path(path + File::SEPARATOR + basename)
lstat = File.lstat path rescue nil
if !lstat || !lstat.directory?
- unless normalize_path(path).start_with? normalize_path(destination_dir) and (FileUtils.mkdir path, mkdir_options rescue false)
+ unless normalize_path(path).start_with? normalize_path(destination_dir) and (FileUtils.mkdir path, **mkdir_options rescue false)
raise Gem::Package::PathError.new(file_name, destination_dir)
end
end