plain_file.rb 413 B

12345678910111213
  1. actions :replace, :append, :insert_if_no_match, :insert_after_match, :remove
  2. attribute :name, :kind_of => String, :name_attribute => true
  3. attribute :owner, :kind_of => String
  4. attribute :group, :kind_of => String
  5. attribute :current_line, :kind_of => String
  6. attribute :new_line, :kind_of => String
  7. attribute :pattern, :kind_of => Regexp
  8. def initialize(*args)
  9. super
  10. @action = :append unless @new_line.nil?
  11. end