My 2nd bug report on echo of BASH: echo -n -e --- both options do not work together

Date:

Thu, 26 Jul 2001 21:03:54 -0400

Hi GNU Team folks,
I am a fan of GNU BASH tools. Here is my 2nd bug report on BASH tools,
now reffered to echo command.
I have noticed that if I use both -n and -e with echo command in a BASH
shell script, they do not work well.
I guess, the way the command line arguments are processed in echo seems
to have some problem.
On the other hand, if I directly test it on the BASH window without
using a BASH script, it works OK.
Examples: I wrote the following commands in a BASH script called 'updt'
with 1st line as #!@/bin/sh
and I got yhe following responses from this echo command, which are
wrong because fo 2 reasons:
1. -n should suppress the trailing new line, but does not do so.
2. -e should interpret the \n\t and new line and tab, but in stead they
are diasplayed as \n and \t.
Command: echo -n-e "Enter return to see $README before you add a new
entry.\n\tEx: grptl1"; read x
Response: -n-e Enter return to see
/cygdrive/z/Public/tools/bin/README.txt before you add a new
entry.\n\tEx: grptl1
Command: echo -n -e "Enter return to see $README before you add a new
entry.\n\tEx: grptl1"; read x
Response: -e Enter return to see /cygdrive/z/Public/tools/bin/README.txt
before you add a new entry.\n\tEx: grptl1
Command: echo -ne "Enter return to see $README before you add a new
entry.\n\tEx: grptl1"; read x
Response: -ne Enter return to see
/cygdrive/z/Public/tools/bin/README.txt before you add a new
entry.\n\tEx: grptl1
Thanks,
Satya

reply via email to

[Prev in Thread]

Current Thread

[Next in Thread]

My 2nd bug report on echo of BASH: echo -n -e --- both options do not work together,
Satya Nemana<=