help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-bash] Current working directory echoed to the terminal


From: Chris Jones
Subject: [Help-bash] Current working directory echoed to the terminal
Date: Mon, 09 Apr 2012 01:48:08 -0400
User-agent: Mutt/1.5.20 (2009-06-14)

Out of curiosity: 

I have recently upgraded to bash v4.1.5 (debian lenny to debian squeeze)
and I noticed that every time I run a bash script that starts with
‘#!/bin/bash’, the current directory is echoed to the terminal. 

I know for a fact that this did not happen before I upgraded since that
is when I started experiencing some unwanted effects.

Interestingly, I was able to work around the problem by replacing
#!/bin/bash by #!/bin/sh. It is unclear why, since /bin/sh is a soft
link to /bin/bash. 

I also noticed that python or awk scripts where the interpreter is
invoked via a ‘sha-bang’ are not affected.

I was able to determine that this happens before any of the script's
instructions are executed so it does not look as if this is a bash
issue proper but more of a bash ‘environment’ issue. 

Nevertheless, maybe someone on this list would be able to point me in
the right direction..?

Thanks,

CJ

-- 
ALL YOUR BASE ARE BELONG TO US!




reply via email to

[Prev in Thread] Current Thread [Next in Thread]