Environment hook

Add initial support for an environment hook and the most basic coverage support as an example (with no options yet).