ENH Add pre-execution hook

Use to in exit_if_file_exits to avoid always running one task.

This point was raised by Sven on the jug-users mailing list. See
discussion at
https://groups.google.com/forum/#!topic/jug-users/PV5jKw0AEgY