One of the scripts I'm working on, has a trap command at the very end.
tap "echo ${myname}: Deployment failure; exit 2" ERR
This command is present in a Script B, which is being called in the middle of another script A.
If the echo command is being executed, can we identify which line in which script (A or B) is giving the ERR signal?