On 4/30/15 9:27 AM, Chet Ramey wrote: > On 4/29/15 10:31 PM, Rocky Bernstein wrote: > >> $ ./bash --debugger -i /tmp/foo.sh >> hi >> >> $ ./bash --debugger /tmp/foo.sh >> bash debugger, bashdb, release 4.3-0.91 >> >> Copyright 2002, 2003, 2004, 2006-2012, 2014 Rocky Bernstein >> This is free software, covered by the GNU General Public License, and you are >> welcome to change it and/or distribute copies of it under certain conditions. >> >> (/tmp/foo.sh:2): >> 2: echo "hi" >> bashdb<0> > > I'll have to look at this. The bash-4.3 behavior was changed to solve > this problem with running the debugger in an interactive shell: > > http://lists.gnu.org/archive/html/bug-bash/2012-08/msg00028.html > > That problem still exists with the version of bashdb installed by default > on my Fedora 20 system. > > It looks like testing for the presence of -i might solve it, but I will > have to see.
It turned out to be a little more complicated than that, but I think I have something that will result in the debugger being invoked only when the shell is reading a shell script. It will be in the next release. Chet -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, ITS, CWRU c...@case.edu http://cnswww.cns.cwru.edu/~chet/