First set of tasks ported from Randy Kahle's plugin