I'm trying to write a program to edit config files and the text is broken up into "paragraphs"
I want to search the file and find the "correct" paragraph - easy can do it with regex.
but from there I want to go down a few lines into say the middle of the paragraph/chunk of text and append to the end of the line, or copy the line do something to it, then write the line back.
example
define object {
objectName name_to_check
useless_info asdfasdf
members member1 member2 .... <- line I want to append to
}
I can't seem to find a way to do this online, any help would be greatly appreciated.