edit handler
fix for shells that do not inherit traps in subshell