Add wrapper function to `git grep` command and minor code cleanup.