dash "echo -e" echoes "-e"

Bug #72167 reported by Romano Giannetti
Affects Status Importance Assigned to Milestone
dash (Ubuntu)

Bug Description

Not sure if it's a bug or a feature, but:

dash > echo -e string
dash > -e string

... which breaks for example the build of pyxplot under edgy, in which the makefile builds some files with "echo -e something > file".

Probably it's not strictly a bug in dash (most probably pyxplot developers should have used /bin/echo instead of echo) but well, I think it's good to report here.

Revision history for this message
Blue (vali-dragnuta) wrote :

I confirm this bug.
Because of it for example xmail does not install (the postinst scripts need to echo -e user pass >ctrlaccounts.tab )
Why is dash included as /bin/sh, anyway ?! It seems a lot of people out there have compatibility problems with this cr*p.

BTW, this is not so much a dash issue but an Ubuntu (as a distro) issue, as dash should have not been included as the default shell anyway - it creates too much compatibility problems. (ubuntu-minimal depends on dash )

Changed in dash:
status: Unconfirmed → Confirmed
Revision history for this message
.:. brainsik (brainsik) wrote :

This also breaks the drbd0.7-module-source package so that it's compilation fails.

I suppose this is the perogative of the DASH author(s), but it breaks the -e option convention used by both the BASH builtin as well as the /bin/echo program.

Revision history for this message
didier (did447-deactivatedaccount) wrote :

in my understanding echo -e is not in POSIX (cf http://www.opengroup.org/onlinepubs/000095399/utilities/echo.html)

Revision history for this message
Micah Cowan (micahcowan) wrote :

One of the driving goals for dash is that it be as POSIX-compliant as possible, which would specifically preclude treating -e (or any other "options") as anything other than a normal argument. printf is much more portable for interpreting escape sequences.

Changed in dash:
status: Confirmed → Rejected
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers