Update Gruntfile.js

Backport latest version based completely on variables