🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.bash.bug
Article #673

Echo and arguments that begin with "-"

#673
From: David Elliott
Date: Fri, 20 Oct 1989 15:09
23 lines
976 bytes
Here's an interesting problem.  In bash, the echo command can take the
options -n and -e.

We are using bash with the C news inews program (our standard sh is
broken and we aren't ready to upgrade to a new release), and inews
wants to do an

	echo "-- "

Bash's echo sees this and gives an invalid flag message.

In this case, I simply changed the line to

	echo "BB " | tr B -

but it seems reasonable to me that there should be a way to say
"There are no more options; process the rest of the line as it
is".

-- 
David Elliott
dce@sony.com | ...!{uunet,mips}!sonyusa!dce
Technical Details
Message-ID: <1989Oct20.150903.5418@sony.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!mips!sony.com!dce

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!mips!sony.com!dce
From: dce@sony.com (David Elliott)
Newsgroups: gnu.bash.bug
Subject: Echo and arguments that begin with "-"
Message-ID: <1989Oct20.150903.5418@sony.com>
Date: 20 Oct 89 15:09:03 GMT
Reply-To: dce@icky.sony.com (David Elliott)
Distribution: gnu
Organization: Sony Microsystems Corp.
Lines: 23