update example scripts to new CLI
add add'l logging
revert debugging code
remove fflush from common shell code
remove unused trap handler
reorganize interactive mode runtime
remove fflush from emit handlers