Re: Unexpected behaviour: double backslash in single quotes

2018-09-06 Thread Joshua Phillips
On Thu, Sep 6, 2018, at 09:40, Joshua Phillips wrote: > Escape sequences don't work in single quotes: > > $ echo 'hello\world' > hello\world > $ echo 'hello\' > hello\ > > Which makes it surprising that double backslashes get converted to > single backslashes: > > $ echo 'hello\\world' >

Re: Unexpected behaviour: double backslash in single quotes

2018-09-06 Thread Eric Blake
On 09/06/2018 04:40 AM, Joshua Phillips wrote: Escape sequences don't work in single quotes: $ echo 'hello\world' hello\world $ echo 'hello\' Warning. Use of 'echo' and backslashes is non-portable. There are two classical behaviors: 1. backslashes are not special to echo unless you pass -e,

Re: Unexpected behaviour: double backslash in single quotes

2018-09-06 Thread Joshua Phillips
On Thu, Sep 6, 2018, at 12:48, Eric Blake wrote: > On 09/06/2018 04:40 AM, Joshua Phillips wrote: > > Escape sequences don't work in single quotes: > > > > $ echo 'hello\world' > > hello\world > > $ echo 'hello\' > > Warning. Use of 'echo' and backslashes is non-portable. There are two >

Re: ${var+set}, ${var:+nonempty} broken in current git

2018-09-06 Thread Martijn Dekker
Op 06-09-18 om 07:07 schreef Herbert Xu: On Wed, Sep 05, 2018 at 06:21:36PM +0200, Martijn Dekker wrote: With this patch applied, the following breakage still occurs: $ src/dash -u -c 'unset foo bar; echo ${foo+${bar}}' src/dash: 1: bar: parameter not set (expected: empty line, no error)

[PATCH] update .gitignore

2018-09-06 Thread Martijn Dekker
Ignore .deps and .dirstamp in all directories. diff --git a/.gitignore b/.gitignore index 579bd47..e349901 100644 --- a/.gitignore +++ b/.gitignore @@ -13,11 +13,12 @@ Makefile.in # generated by configure Makefile +.deps +.dirstamp /config.cache /config.h /config.log /config.status