For example, if you need to make sure that a particular package is unmasked in /etc/portage/package.keywords/local, you can use string_replacer to put it there without disturbing the other lines.
Seamus Abshere
gem "string_replacer", "~> 0.0.1"