I'm in need of a regex and hopefully someone can help me out. I'm looping through a text file that contains lines such as the following:
I need a regex that will return some_text4 whenever it finds the word FOUND. In other words, I need the word that comes before a given word in a line of text.
One more thing that might help. Given the example above, some_text3 will always end with a colon (:).
Any suggestions would be much appreciated.