You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(PUP-3030) Flesh out implementation of P::F::Tempfile
This commit changes `Puppet::FileSystem::Tempfile` so that
it no longer subclasses the built-in `Tempfile`. The goal
here is to give us more control over the life cycle of the
files when used on the server.
The implementation is based on the Ruby 1.9.3 implementation of
`Tempfile`, but strips out some things like the finalizer
and methods that we don't need / use.
Note that we had to also port over a few methods from `Dir` in
order to support ruby 1.8.7. Relevant source code is here:
https://github.com/ruby/ruby/blob/v1_9_3_547/lib/tempfile.rbhttps://github.com/ruby/ruby/blob/v1_9_3_547/lib/tmpdir.rb
In its current incarnation the class is probably poorly
named because it no longer makes any attempt to automagically
unlink the file at some point in the future. I intend
to submit a follow-up commit that renames the class to make
this more obvious.
0 commit comments