[rubygems/rubygems] Extract a local variable
https://github.com/rubygems/rubygems/commit/445c9da2ac
This commit is contained in:
parent
ece1690105
commit
a453f26b0d
Notes:
git
2020-05-08 14:14:16 +09:00
@ -130,10 +130,11 @@ module Bundler
|
|||||||
end]
|
end]
|
||||||
|
|
||||||
if man_pages.include?(command)
|
if man_pages.include?(command)
|
||||||
|
man_page = man_pages[command]
|
||||||
if Bundler.which("man") && man_path !~ %r{^file:/.+!/META-INF/jruby.home/.+}
|
if Bundler.which("man") && man_path !~ %r{^file:/.+!/META-INF/jruby.home/.+}
|
||||||
Kernel.exec "man #{man_pages[command]}"
|
Kernel.exec "man #{man_page}"
|
||||||
else
|
else
|
||||||
puts File.read("#{man_path}/#{File.basename(man_pages[command])}.txt")
|
puts File.read("#{man_path}/#{File.basename(man_page)}.txt")
|
||||||
end
|
end
|
||||||
elsif command_path = Bundler.which("bundler-#{cli}")
|
elsif command_path = Bundler.which("bundler-#{cli}")
|
||||||
Kernel.exec(command_path, "--help")
|
Kernel.exec(command_path, "--help")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user