[rubygems/rubygems] Improve comment explaining the neccessity of write_default_spec method.

The intention is not obvious from the commit log and it might avoid
temptation to remove the method without further consideration.

https://github.com/rubygems/rubygems/commit/8e17c50f64
This commit is contained in:
Vít Ondruch 2019-09-11 15:33:04 +02:00 committed by Hiroshi SHIBATA
parent f3d69bed62
commit 69460791cc
No known key found for this signature in database
GPG Key ID: F9CF13417264FAC2

View File

@ -461,6 +461,9 @@ class Gem::Installer
## ##
# Writes the full .gemspec specification (in Ruby) to the gem home's # Writes the full .gemspec specification (in Ruby) to the gem home's
# specifications/default directory. # specifications/default directory.
#
# In contrast to #write_spec, this keeps file lists, so the `gem contents`
# command works.
def write_default_spec def write_default_spec
Gem.write_binary(default_spec_file, spec.to_ruby) Gem.write_binary(default_spec_file, spec.to_ruby)