I'm trying to do the following..
if "ps | grep -e file" then
true;
else
false;
What would I need to do to make the string n the if statement execute the linux command listed?
Simply use system("command"). It'll return true if the command was successfully executed.
EDIT Just read your question again, and I believe that what you're looking for is this:
if `ps | grep -e file`.empty? # no matches
true
else
false
end