This is the mail archive of the cygwin mailing list for the Cygwin project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
On 25/05/2017 11:57, Pavel Fedin wrote:
Hello!Hello! I'd like to report a strange bug in 64-bit bash. The following script: ---- cut --- #/bin/bash -e DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" echo Works: $DIR ---- cut --- Simply exits and produces no output (never reaches echo). The same script works perfectlyon 32 bits. Versions are the same:--- cut ---It works fine for me. $ ./prova.bash Works: /tmpHuh, works here too, indeed. But there's one little thing. If you just copypasted this from my email, then you probably miss "#!" (there's just "#", since i retyped the header, and made a typo). And with this typo it really works for some reason. Could you make sure once again ? Apparently it has to do with -e switch.
$ ./prova_bash Works: /cygdrive/e/cygwin/tmp $ cat prova_bash #!/bin/bash -e DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" echo Works: $DIR -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |