Ok, I tried to delete lines that contain -- from a file. The file looks like this:
----------------------------------------------------------------- Lorem ip
As others said, you can do it with grep, but if you want to do it completely in Ruby, then look at this question, the first answer should help you.