trap-event
DEBUG
Run before simple commands and other documented constructs. Trace only trusted fixtures, and reset when finished.
Formal Syntax & Structure
bash syntaxbash
trap action DEBUGReturn Value
event
Run before simple commands and other documented constructs. Trace only trusted fixtures, and reset when finished.
Working Example
Example Snippetbash
trap 'printf "debug\n" >&2' DEBUGprintf 'one\n'trap - DEBUGprintf 'two\n'