Grep fix for Mountain Lion Contributed by Alan McSeveney <alan@themill.com>