Previously we had separate code paths for echoing commands (-x)
and tracing (guestfs_set_trace). This just unifies that so that
the guestfish -x option enables tracing.
int read_only = 0;
int quit = 0;
int verbose = 0;
-int echo_commands = 0;
int remote_control_listen = 0;
int remote_control = 0;
int exit_on_error = 1;
exit (EXIT_SUCCESS);
case 'x':
- echo_commands = 1;
+ guestfs_set_trace (g, 1);
break;
case HELP_OPTION:
/* This counts the commands issued, starting at 1. */
command_num++;
- if (echo_commands) {
- printf ("%s", cmd);
- for (i = 0; argv[i] != NULL; ++i)
- printf (" %s", argv[i]);
- printf ("\n");
- }
-
/* For | ... commands. Annoyingly we can't use popen(3) here. */
if (pipecmd) {
int fd[2];