Sometimes the BASH debugger gets confused about where to find the script
source file for the name reported to it by bash. To resolve relative
file names that bash supplies via BASH_SOURCE
, the BASH debugger uses
the current working directory when the debugged script was started as
well as the current working directory now (which might be different
if a “cd” command was issued to change the working directory).
However sometimes this doesn’t work and there is a way to override this.
file script-file
¶Directs the BASH debugger to use script-file whenever bash would have
it refers to the filename given in BASH_SOURCE
. The filename
specified in BASH_SOURCE
that gets overridden is shown when is
this command is issued.