Skip to content

Commit ae032bd

Browse files
authored
Merge pull request #779 from jbondpdx/master
(FM-6197) formatting fixes for file_line resource
2 parents 1862076 + 3ec177e commit ae032bd

File tree

1 file changed

+67
-67
lines changed

1 file changed

+67
-67
lines changed

README.md

Lines changed: 67 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -145,89 +145,89 @@ Files with special characters that are not valid UTF-8 give the error message "I
145145

146146
**Autorequires:** If Puppet is managing the file that contains the line being managed, the `file_line` resource autorequires that file.
147147

148-
##### Parameters
148+
**Parameters**
149149

150150
All parameters are optional, unless otherwise noted.
151151

152-
* `after`
152+
##### `after`
153153

154-
Specifies the line after which Puppet adds any new lines using a regular expression. (Existing lines are added in place.)
154+
Specifies the line after which Puppet adds any new lines using a regular expression. (Existing lines are added in place.)
155155

156-
Values: String containing a regex.
157-
158-
Default value: `undef`.
159-
160-
* `encoding`
161-
162-
Specifies the correct file encoding.
156+
Values: String containing a regex.
163157

164-
Values: String specifying a valid Ruby character encoding.
165-
166-
Default: 'UTF-8'.
158+
Default value: `undef`.
167159

168-
* `ensure`: Specifies whether the resource is present.
160+
##### `encoding`
169161

170-
Values: 'present', 'absent'.
171-
172-
Default value: 'present'.
173-
174-
* `line`
162+
Specifies the correct file encoding.
175163

176-
**Required.**
177-
178-
Sets the line to be added to the file located by the `path` parameter.
179-
180-
Values: String.
181-
182-
* `match`
164+
Values: String specifying a valid Ruby character encoding.
183165

184-
Specifies a regular expression to compare against existing lines in the file; if a match is found, it is replaced rather than adding a new line. A regex comparison is performed against the line value, and if it does not match, an exception is raised.
185-
186-
Values: String containing a regex.
187-
188-
Default value: `undef`.
189-
166+
Default: 'UTF-8'.
190167

191-
* `match_for_absence`
168+
##### `ensure`: Specifies whether the resource is present.
192169

193-
Specifies whether a match should be applied when `ensure => absent`. If set to `true` and match is set, the line that matches is deleted. If set to `false` (the default), match is ignored when `ensure => absent` and the value of `line` is used instead. Ignored when `ensure => present`.
194-
195-
Boolean.
196-
197-
Default value: `false`.
198-
199-
* `multiple`
170+
Values: 'present', 'absent'.
200171

201-
Specifies whether `match` and `after` can change multiple lines. If set to `false`, an exception is raised if more than one line matches.
202-
203-
Values: `true`, `false`.
204-
205-
Default value: `false`.
206-
207-
208-
* `name`
172+
Default value: 'present'.
209173

210-
Specifies the name to use as the identity of the resource. If you want the resource namevar to differ from the supplied `title` of the resource, specify it with `name`.
211-
212-
Values: String.
213-
214-
Default value: The value of the title.
215-
216-
* `path`
174+
##### `line`
217175

218-
**Required.**
219-
220-
Specifies the file in which Puppet ensures the line specified by `line`.
221-
222-
Value: String specifying an absolute path to the file.
223-
224-
* `replace`
176+
**Required.**
225177

226-
Specifies whether the resource overwrites an existing line that matches the `match` parameter. If set to `false` and a line is found matching the `match` parameter, the line is not placed in the file.
227-
228-
Boolean.
178+
Sets the line to be added to the file located by the `path` parameter.
179+
180+
Values: String.
229181

230-
Default value: `true`.
182+
##### `match`
183+
184+
Specifies a regular expression to compare against existing lines in the file; if a match is found, it is replaced rather than adding a new line. A regex comparison is performed against the line value, and if it does not match, an exception is raised.
185+
186+
Values: String containing a regex.
187+
188+
Default value: `undef`.
189+
190+
191+
##### `match_for_absence`
192+
193+
Specifies whether a match should be applied when `ensure => absent`. If set to `true` and match is set, the line that matches is deleted. If set to `false` (the default), match is ignored when `ensure => absent` and the value of `line` is used instead. Ignored when `ensure => present`.
194+
195+
Boolean.
196+
197+
Default value: `false`.
198+
199+
##### `multiple`
200+
201+
Specifies whether `match` and `after` can change multiple lines. If set to `false`, an exception is raised if more than one line matches.
202+
203+
Values: `true`, `false`.
204+
205+
Default value: `false`.
206+
207+
208+
##### `name`
209+
210+
Specifies the name to use as the identity of the resource. If you want the resource namevar to differ from the supplied `title` of the resource, specify it with `name`.
211+
212+
Values: String.
213+
214+
Default value: The value of the title.
215+
216+
##### `path`
217+
218+
**Required.**
219+
220+
Specifies the file in which Puppet ensures the line specified by `line`.
221+
222+
Value: String specifying an absolute path to the file.
223+
224+
##### `replace`
225+
226+
Specifies whether the resource overwrites an existing line that matches the `match` parameter. If set to `false` and a line is found matching the `match` parameter, the line is not placed in the file.
227+
228+
Boolean.
229+
230+
Default value: `true`.
231231

232232
### Data types
233233

@@ -895,7 +895,7 @@ userlist:
895895
ensure_resources('user', hiera_hash('userlist'), {'ensure' => 'present'})
896896
```
897897
898-
### `flatten`
898+
#### `flatten`
899899
900900
Flattens deeply nested arrays and returns a single flat array as a result.
901901

0 commit comments

Comments
 (0)