Sha256: 415bd0efa428cdfecb951214182826ad2575c2b2179a67201da2ffcb5615378b

Contents?: true

Size: 569 Bytes

Versions: 214

Compression:

Stored size: 569 Bytes

Contents

# Store a specified file in our filebucket.
Puppet::Face.define(:file, '0.0.1') do
  action :store do |*args|
    summary "Store a file in the local filebucket."
    arguments "<file>"
    returns "Nothing."
    examples <<-EOT
      Store a file:

      $ puppet file store /root/.bashrc
    EOT

    when_invoked do |path, options|
      file = Puppet::FileBucket::File.new(Puppet::FileSystem.pathname(path))

      Puppet::FileBucket::File.indirection.terminus_class = :file
      Puppet::FileBucket::File.indirection.save file
      file.checksum
    end
  end
end

Version data entries

214 entries across 214 versions & 2 rubygems

Version Path
puppet-retrospec-1.8.0 vendor/pup410/lib/puppet/face/file/store.rb
puppet-retrospec-1.7.0 vendor/pup410/lib/puppet/face/file/store.rb
puppet-4.10.12 lib/puppet/face/file/store.rb
puppet-4.10.12-x86-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.12-x64-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.12-universal-darwin lib/puppet/face/file/store.rb
puppet-4.10.11 lib/puppet/face/file/store.rb
puppet-4.10.11-x86-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.11-x64-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.11-universal-darwin lib/puppet/face/file/store.rb
puppet-4.10.10 lib/puppet/face/file/store.rb
puppet-4.10.10-x86-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.10-x64-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.10-universal-darwin lib/puppet/face/file/store.rb
puppet-retrospec-1.6.1 vendor/pup410/lib/puppet/face/file/store.rb
puppet-retrospec-1.6.0 vendor/pup410/lib/puppet/face/file/store.rb
puppet-4.10.9 lib/puppet/face/file/store.rb
puppet-4.10.9-x86-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.9-x64-mingw32 lib/puppet/face/file/store.rb
puppet-4.10.9-universal-darwin lib/puppet/face/file/store.rb