Method: Puppet::ModuleTool::Tar.instance

Defined in:
lib/puppet/module_tool/tar.rb

.instanceObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



10
11
12
13
14
15
16
17
18
19
# File 'lib/puppet/module_tool/tar.rb', line 10

def self.instance
  if Puppet.features.minitar? && Puppet.features.zlib?
    Mini.new
  elsif Puppet::Util.which('tar') && !Puppet::Util::Platform.windows?
    Gnu.new
  else
    # TRANSLATORS "tar" is a program name and should not be translated
    raise RuntimeError, _('No suitable tar implementation found')
  end
end