Is there some way to get bash into a sort of verbose mode where, such that, when it\'s running a shell script, it echoes out the command it\'s going to run before running it? T
Two useful shell options that can be added to the bash command line or via the set command in a script or interactive session:
- -v Print shell input lines as they are read.
- -x After expanding each simple command,
forcommand,casecommand,selectcommand, or arithmeticforcommand, display the expanded value ofPS4, followed by the command and its expanded arguments or associated word list.