Revising variable names and optionalness

Also replacing %s with {{.src}} in the check_cmd to get around Jinja
templating. Couldn't find any other way that didn't result in {#.src#}.