Class: Ansible::Ruby::Modules::Replace
- Inherits:
-
Base
- Object
- Ansible::Ruby::Models::Base
- Base
- Ansible::Ruby::Modules::Replace
- Defined in:
- lib/ansible/ruby/modules/generated/core/files/replace.rb
Overview
This module will replace all instances of a pattern within a file. It is up to the user to maintain idempotence by ensuring that the same pattern would never match any replacements made.
Instance Method Summary collapse
-
#backup ⇒ :yes, ...
Create a backup file including the timestamp information so you can get the original file back if you somehow clobbered it incorrectly.
-
#dest ⇒ String
The file to modify.
-
#follow ⇒ :yes, ...
This flag indicates that filesystem links, if they exist, should be followed.
-
#others ⇒ Object?
All arguments accepted by the M(file) module also work here.
-
#regexp ⇒ String
The regular expression to look for in the contents of the file.
-
#replace ⇒ String?
The string to replace regexp matches.
Methods inherited from Base
Methods inherited from Ansible::Ruby::Models::Base
attr_option, attr_options, attribute, #initialize, remove_existing_validations, #to_h, validates
Constructor Details
This class inherits a constructor from Ansible::Ruby::Models::Base
Instance Method Details
#backup ⇒ :yes, ...
24 |
# File 'lib/ansible/ruby/modules/generated/core/files/replace.rb', line 24 attribute :backup |
#dest ⇒ String
12 |
# File 'lib/ansible/ruby/modules/generated/core/files/replace.rb', line 12 attribute :dest |
#follow ⇒ :yes, ...
31 |
# File 'lib/ansible/ruby/modules/generated/core/files/replace.rb', line 31 attribute :follow |
#others ⇒ Object?
28 |
# File 'lib/ansible/ruby/modules/generated/core/files/replace.rb', line 28 attribute :others |
#regexp ⇒ String
16 |
# File 'lib/ansible/ruby/modules/generated/core/files/replace.rb', line 16 attribute :regexp |
#replace ⇒ String?
20 |
# File 'lib/ansible/ruby/modules/generated/core/files/replace.rb', line 20 attribute :replace |