Return all files in this gem that match for glob
.
Checks the permissions of the credentials file. If they are not 0600 an error message is displayed and RubyGems aborts.
Reads time of last update check from state file
Writes time of last update check to state file
Performs various checks before installing the gem such as the install repository is writable and its directories exist, required Ruby and rubygems versions are met and that dependencies are installed.
Version and dependency checks are skipped if this install is forced.
The dependent check will be skipped if the install is ignoring dependencies.
Writes the .gem file to the cache directory
Given a name and requirement, downloads this gem into cache and returns the filename. Returns nil if the gem cannot be located.
Downloads uri
to path
if necessary. If no path is given, it just passes the data.
Extracts S3 configuration for S3 bucket
Find
and fetch gem name tuples that match dependency
.
If matching_platform
is false, gems for all platforms are returned.
@return true if the specs of any default gems are ‘==` to the given `spec`.
Choose from a list of options. question
is a prompt displayed above the list. list
is a list of option strings. Returns the pair [option_name, option_index].
Performance optimization
Parsing with ripper is expensive If we know we don’t have any blocks with invalid syntax, then we know we cannot have found the incorrect syntax yet.
When an invalid block is added onto the frontier check document state
Builds blocks from bottom up
Calls the block with each capitalized field name:
res = Net::HTTP.get_response(hostname, '/todos/1') res.each_capitalized_name do |key| p key if key.start_with?('C') end
Output:
"Content-Type" "Connection" "Cache-Control" "Cf-Cache-Status" "Cf-Ray"
The capitalization is system-dependent; see Case Mapping.
Returns an enumerator if no block is given.
Check whether the object_id id
is in the current buffer of objects to be pretty printed. Used to break cycles in chains of objects to be pretty printed.