If the SOURCE_DATE_EPOCH environment variable is set, returns it’s value. Otherwise, returns the time that Gem.source_date_epoch_string
was first called in the same format as SOURCE_DATE_EPOCH.
NOTE(@duckinator): The implementation is a tad weird because we want to:
1. Make builds reproducible by default, by having this function always return the same result during a given run. 2. Allow changing ENV['SOURCE_DATE_EPOCH'] at runtime, since multiple tests that set this variable will be run in a single process.
If you simplify this function and a lot of tests fail, that is likely due to #2 above.
Details on SOURCE_DATE_EPOCH: reproducible-builds.org/specs/source-date-epoch/
Find
an unresolved Gem::Specification
of default gem from path
Initializes this object from orig if it can be duplicated/cloned and returns it.
Constructs a new source range by finding the given character between the given start offset and end offset. If the needle is not found, it returns nil. Importantly it does not search past newlines or comments.
Note that end_offset is allowed to be nil, in which case this will search until the end of the string.
Within the given block, track that we’re within a pattern.
Parse an integer from the string representation.
Apply Ruby
string escaping rules
The X509
certificate chain for this socket’s peer.
Returns the last Finished message received
begin end ^^^^^^^^^
case foo; in bar; end ^^^^^^^^^^^^^^^^^^^^^
Visit an individual part of a string-like node.
“foo” ^^^^^