forward command line return code to console and remote control