Commit de6dc5f
match section names containing prefix character
Currently sections with names including the prefix (normally [) can be
created by this provider, but they are then not matched by the regex,
meaning puppet will create a new section (with the same name) every time
it runs. Fix that by allowing the section prefix in the section name.
Any line that starts with the correct prefix (normally [) and ends with
the correct suffix (normally ]) is treated as a valid section header,
regardless of what is between them.
This is needed for splunk inputs.conf file where regexes, including
square brackets, are allowed inside the section name.1 parent a0ef2bd commit de6dc5f
1 file changed
Lines changed: 1 addition & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
35 | | - | |
36 | 34 | | |
37 | 35 | | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
| 36 | + | |
47 | 37 | | |
48 | 38 | | |
49 | 39 | | |
| |||
0 commit comments