How to remove a section in inifile?

33 views
Skip to first unread message

Vadym Chepkov

unread,
Feb 3, 2016, 4:48:20 PM2/3/16
to puppet...@googlegroups.com

Hi,

Is there way to remove a whole section from an inifile ?

For example,

[section]

Removing settings from the section you can do with puppetlabs-inifile module:

ini_setting { 'made a mistake':
ensure => absent,
path => $config_file,
section => 'section',
setting => $setting,
}

But how to remove empty section itself?

Thanks,
Vadym


Reply all
Reply to author
Forward
0 new messages