bash-4.3: casemod word expansions broken with UTF-8

2015-11-16 Thread Ulrich Mueller
Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: x86_64-pc-linux-gnu-gcc Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-pc-linux-gnu' -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/s

Re: redirecting a file descriptor to an array variable? Possible? How? RFE?

2015-11-16 Thread Greg Wooledge
On Sun, Nov 15, 2015 at 05:26:26AM -0800, Linda Walsh wrote: > Note that printf *can* print out nul bytes: Yes, of course it can: printf '\0' This can be used to serialize an array into a file: printf '%s\0' "${array[@]}" > file And to read it back: array=(); while IFS= read -rd '' x; d

Re: redirecting a file descriptor to an array variable? Possible? How? RFE?

2015-11-16 Thread konsolebox
On Fri, Nov 13, 2015 at 8:45 AM, Linda Walsh wrote: > > I'd like to be able to record stdout and stderr > without using any temp files into bash array files, AND > record the status of the command executed. > You can use coproc processes that would act as buffers. Obvious Note: Avoid it if you're

Re: bash-4.3: casemod word expansions broken with UTF-8

2015-11-16 Thread Ulrich Mueller
> On Sun, 15 Nov 2015, Ulrich Mueller wrote: > Description: > In an UTF-8 locale like en_US.UTF-8, the case-modifying > parameter expansions sometimes return invalid UTF-8 encodings. > This seems to happen when the UTF-8 byte sequences that are > encoding upper and low

bash-4.3: casemod word expansions broken with UTF-8

2015-11-16 Thread Ulrich Mueller
[Resending, apparently my first message didn't make it to the list.] Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: x86_64-pc-linux-gnu-gcc Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_

"fc" builtin exits with unexpected status

2015-11-16 Thread Chris Marusich
Hi, I like to set up my PS1 to show the exit status of the last command I ran. I've noticed that this doesn't seem to work as expected when I use the "fc" builtin. When I do the following, the final exit status appears to be reported as "1", even though true always exits with status 0. $ export

Re: bash-4.3: casemod word expansions broken with UTF-8

2015-11-16 Thread Chet Ramey
On 11/15/15 8:46 AM, Ulrich Mueller wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: x86_64-pc-linux-gnu-gcc > Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' > -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_6

Re: bash-4.3: casemod word expansions broken with UTF-8

2015-11-16 Thread isabella parakiss
On 11/15/15, Ulrich Mueller wrote: > Description: > In an UTF-8 locale like en_US.UTF-8, the case-modifying > parameter expansions sometimes return invalid UTF-8 encodings. > > This seems to happen when the UTF-8 byte sequences that are > encoding upper and lower case have

Re: bash-4.3: casemod word expansions broken with UTF-8

2015-11-16 Thread Ulrich Mueller
> On Mon, 16 Nov 2015, Chet Ramey wrote: > Thanks for the report. This was fixed back in January as a result of > this bug report: > http://lists.gnu.org/archive/html/bug-bash/2015-01/msg00091.html > and the fix is in bash-4.4-beta. Please try that and let me know > your results. Indeed,