Added the ability to run commands from within a template.