1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

[rubygems/rubygems] Fix installing template files with dots

https://github.com/rubygems/rubygems/commit/a82a77251d
This commit is contained in:
David Rodríguez 2020-06-02 10:19:41 +02:00 committed by Hiroshi SHIBATA
parent 1f9e684c77
commit e4d0cca24a
Notes: git 2020-06-05 07:33:45 +09:00
2 changed files with 6 additions and 1 deletions

View file

@ -547,7 +547,7 @@ By default, this RubyGems will install gem as:
def bundler_template_files def bundler_template_files
Dir.chdir "bundler/lib" do Dir.chdir "bundler/lib" do
Dir[File.join('bundler', 'templates', '**', '{*,.*}')]. Dir.glob(File.join('bundler', 'templates', '**', '*'), File::FNM_DOTMATCH).
select{|f| !File.directory?(f)} select{|f| !File.directory?(f)}
end end
end end

View file

@ -28,6 +28,8 @@ class TestGemCommandsSetupCommand < Gem::TestCase
bundler/exe/bundle bundler/exe/bundle
bundler/lib/bundler.rb bundler/lib/bundler.rb
bundler/lib/bundler/b.rb bundler/lib/bundler/b.rb
bundler/lib/bundler/templates/.circleci/config.yml
bundler/lib/bundler/templates/.travis.yml
bundler/man/bundle-b.1 bundler/man/bundle-b.1
bundler/man/bundle-b.1.txt bundler/man/bundle-b.1.txt
bundler/man/gemfile.5 bundler/man/gemfile.5
@ -184,6 +186,9 @@ class TestGemCommandsSetupCommand < Gem::TestCase
assert_path_exists File.join(dir, 'bundler.rb') assert_path_exists File.join(dir, 'bundler.rb')
assert_path_exists File.join(dir, 'bundler/b.rb') assert_path_exists File.join(dir, 'bundler/b.rb')
assert_path_exists File.join(dir, 'bundler/templates/.circleci/config.yml')
assert_path_exists File.join(dir, 'bundler/templates/.travis.yml')
end end
end end