Added pre-execute hooks
Merge pull request #125 from JuliaLang/malmaud/preexecute

Added pre-execute hooks