Refactor to be a grunt plugin