Why don't you pass the file to `grep` itself?