class Producer::Core::Actions::FileWriter

Public Instance Methods

apply() click to toggle source
# File lib/producer/core/actions/file_writer.rb, line 15
def apply
  fs.file_write @path, @content
  fs.setstat @path, options unless options.empty?
end
name() click to toggle source
# File lib/producer/core/actions/file_writer.rb, line 11
def name
  'file_write'
end
setup() click to toggle source
# File lib/producer/core/actions/file_writer.rb, line 5
def setup
  check_arguments_size! arguments_size
  @path, @content = arguments
  convert_options mode: :permissions, user: :owner
end

Private Instance Methods

arguments_size() click to toggle source
# File lib/producer/core/actions/file_writer.rb, line 22
def arguments_size
  2
end