Re: [PATCH] glob: add shopt globmtimesort to sort globs by mtime

2022-11-16 Thread Alex fxmbsw7 Ratchev
On Tue, Nov 15, 2022, 09:33 Alex fxmbsw7 Ratchev wrote: > i d be all for changeable glob s appearing > by chance integrate into loops expansion of array vars .. not just file globs .. > > On Tue, Nov 15, 2022, 02:40 Chet Ramey wrote: > >> On 10/3/22 2:56

Re: [PATCH] glob: add shopt globmtimesort to sort globs by mtime

2022-11-15 Thread Alex fxmbsw7 Ratchev
i d be all for changeable glob s appearing On Tue, Nov 15, 2022, 02:40 Chet Ramey wrote: > On 10/3/22 2:56 PM, Evan Gates wrote: > > --- > > > > There is currently no good way to sort files by mtime in the shell. > > It's possible to do so with an ls that supports -t, but parsing ls is > >

Re: string substitution broken since 5.2

2022-11-04 Thread Alex fxmbsw7 Ratchev
On Fri, Nov 4, 2022, 19:42 Chet Ramey wrote: > On 11/4/22 12:22 PM, Alex fxmbsw7 Ratchev wrote: > > > what on yours i ask , o i see now , 4.2 .. > > i quote right in ${ // - to me , preserved quotes are • an invalid youth > > bug to be replaced with better by

Re: string substitution broken since 5.2

2022-11-04 Thread Alex fxmbsw7 Ratchev
> i_&_foo --> i_&_foo sorry short imo , the ' " not parsing is outdated , and got fixed later u may want bash v<1 compatibility ? i just say its two horsrs , one about old and keep , the other about new and updated On Fri, Nov 4, 2022, 17:22 Alex fxmbsw7 Ratchev wrote

Re: string substitution broken since 5.2

2022-11-04 Thread Alex fxmbsw7 Ratchev
On Fri, Nov 4, 2022, 17:03 Greg Wooledge wrote: > On Fri, Nov 04, 2022 at 01:30:16PM +0100, Alex fxmbsw7 Ratchev wrote: > > > 1) Put something like "shopt -u patsub_replacement 2>/dev/null || true" > > >at the top of your script. > > > &

Re: string substitution broken since 5.2

2022-11-04 Thread Alex fxmbsw7 Ratchev
that u word comply to very outdated specs i did word bye On Fri, Nov 4, 2022, 15:26 Martin D Kealey wrote: > I now very much regret not commenting on this proposal during the > pre-release period, and I apologise for not having done so. > > On Fri, 4 Nov 2022, 05:50 Chet Ramey, wrote: > > > >

Re: string substitution broken since 5.2

2022-11-04 Thread Alex fxmbsw7 Ratchev
On Fri, Nov 4, 2022, 12:33 Greg Wooledge wrote: > On Fri, Nov 04, 2022 at 09:50:03AM +0100, Alex fxmbsw7 Ratchev wrote: > > On Fri, Nov 4, 2022, 08:56 Léa Gris wrote: > > > > > Le 03/11/2022 à 19:50, Chet Ramey écrivait : > > > > The option is enable

Re: string substitution broken since 5.2

2022-11-04 Thread Alex fxmbsw7 Ratchev
On Fri, Nov 4, 2022, 08:56 Léa Gris wrote: > Le 03/11/2022 à 19:50, Chet Ramey écrivait : > > The option is enabled by default. If you want to restore the previous > > behavior, add `shopt -u patsub_replacement'. > > Having it enabled by default is not good, because it introduces > side-effects

Re: local/typeset/declare -p - outputs invalid declare -- -

2022-10-31 Thread Alex fxmbsw7 Ratchev
On Mon, Oct 31, 2022, 18:31 Greg Wooledge wrote: > On Mon, Oct 31, 2022 at 06:12:14PM +0100, Alex fxmbsw7 Ratchev wrote: > > hi , sorry.. whats the purpose of local - > > informational question > > a. Since there is no `declare -' equivalent of `local -', make su

Re: Multiline editing breaks if the previous output doesn't end in newline

2022-10-31 Thread Alex fxmbsw7 Ratchev
where the cursor is ? some tput ansi code returns it .. but i guess u mean bigger compatibility problems does, readline, export its cursor assumptations ? like for dev'ing On Mon, Oct 31, 2022, 16:46 Chet Ramey wrote: > On 10/30/22 9:40 PM, Oğuz wrote: > > > Yeah, or add a new prompt sequence

Re: local/typeset/declare -p - outputs invalid declare -- -

2022-10-31 Thread Alex fxmbsw7 Ratchev
hi , sorry.. whats the purpose of local - informational question On Mon, Oct 31, 2022, 17:45 Emanuele Torre wrote: > Since bash 5.2, local/typeset/declare -p without argument no longer > outputs "declare -- -" when local - is used. > > But local/typeset/declare -p - still outputs "declare

Re: Multiline editing breaks if the previous output doesn't end in newline

2022-10-30 Thread Alex fxmbsw7 Ratchev
On Sun, Oct 30, 2022, 23:01 Dennis Williamson wrote: > > > On Sun, Oct 30, 2022 at 4:41 PM Alex fxmbsw7 Ratchev > wrote: > >> >> >> i coded a files tree to bash code via gawk reading and printing bash code >> i did noeol no newline at end >> l

Re: Multiline editing breaks if the previous output doesn't end in newline

2022-10-30 Thread Alex fxmbsw7 Ratchev
On Sun, Oct 30, 2022, 21:21 Albert Vaca Cintora wrote: > On Sun, Oct 30, 2022 at 7:54 AM Martin D Kealey > wrote: > > > > This sounds like a bug in whatever is producing the output. POSIX text > files have a newline terminating every line; that description includes > streams going through pipes

Re: bash "extglob" needs to upgrade at least like zsh "kshglob"

2022-10-30 Thread Alex fxmbsw7 Ratchev
On Sun, Oct 30, 2022, 11:33 Oğuz wrote: > 30 Ekim 2022 Pazar tarihinde Martin D Kealey > yazdı: > > > > So the options would seem to be: > > (a) prohibit inversions (you get to pick EITHER extglob or rexglob, not > > both); > > (b) bypass convert-to-regex when inversions are present; > > (c)

Re: feature request: new builtin `defer`, scope delayed eval

2022-10-12 Thread Alex fxmbsw7 Ratchev
On Sat, Oct 8, 2022, 12:03 Oğuz wrote: > 8 Ekim 2022 Cumartesi tarihinde Cynthia Coan yazdı: > > > > [...] I think > > use cases outside of cleanup are relatively sparse, [...] > > > There. There already are several ways to do cleanup on exit/return using > existing features, why add one more?

Re: Light weight support for JSON

2022-08-28 Thread Alex fxmbsw7 Ratchev
positive feedback from others readers. Yair. > ah, cool i just have a suggestion, .. to store the keys in a separate array, space safe On Sun, Aug 28, 2022 at 9:42 AM Alex fxmbsw7 Ratchev > wrote: > >> >> >> On Sun, Aug 28, 2022, 15:25 Yair Lenga wrote: >> >

Re: Light weight support for JSON

2022-08-28 Thread Alex fxmbsw7 Ratchev
On Sun, Aug 28, 2022, 15:25 Yair Lenga wrote: > Hi, > > Over the last few years, JSON data becomes a integral part of processing. > In many cases, I find myself having to automate tasks that require > inspection of JSON response, and in few cases, construction of JSON. So > far, I've taken one

Re: ${!#} doesnt get into history in interactive

2022-08-25 Thread Alex fxmbsw7 Ratchev
On Thu, Aug 25, 2022, 16:27 Chet Ramey wrote: > On 8/25/22 2:04 AM, Alex fxmbsw7 Ratchev wrote: > > > > > is this a bug, i see it as wrong feature > > > > the set -- 1 2 3 line was also gone - why ? > > > > it printed for !# 3 it didnt histexpand-act

Re: ${!#} doesnt get into history in interactive

2022-08-25 Thread Alex fxmbsw7 Ratchev
On Wed, Aug 24, 2022, 21:15 Dennis Williamson wrote: > > > On Wed, Aug 24, 2022, 9:07 AM Alex fxmbsw7 Ratchev > wrote: > >> debian 5.2.0(1)-beta bash >> >> i did code lightly in interactive >> then i did >> >> set -- 1 2 3 >> ec

Re: add custom environment variable in bash source code

2022-08-17 Thread Alex fxmbsw7 Ratchev
On Thu, Aug 18, 2022, 04:10 Dale R. Worley wrote: > Sam writes: > > You probably want to edit /etc/ld.so.conf or /etc/ld.so.conf.d/* instead. > > The overall concept is that you almost certainly don't want to modify > the bash source code (and thus executable) to do this. > > In general, if you

Re: Re: Re: add custom environment variable in bash source code

2022-08-17 Thread Alex fxmbsw7 Ratchev
no .. i say im not good at .c yet On Thu, Aug 18, 2022, 01:36 wrote: > Sorry, I don't understand what you want me, you can send a .diff file > tells me how to do? > > 在 2022-08-18 07:26:45,"Alex fxmbsw7 Ratchev" 写道: > > > > > On Thu, Aug 18, 2022, 01:19

Re: Re: add custom environment variable in bash source code

2022-08-17 Thread Alex fxmbsw7 Ratchev
( or use the eval function ( dunno its name and usage ) and eval your two var assignments ) On Thu, Aug 18, 2022, 01:26 Alex fxmbsw7 Ratchev wrote: > > > On Thu, Aug 18, 2022, 01:19 wrote: > >> >> Because I'm using Android, Android doesn't support #!/bi

Re: Re: add custom environment variable in bash source code

2022-08-17 Thread Alex fxmbsw7 Ratchev
dify the source code of bash to make it effective, not the bash.bashrc and > profile files in the etc directory,what should I do, can you send a video > attachment to teach me? > erm, im not yet a .c number > 在 2022-08-18 00:19:24,"Alex fxmbsw7 Ratchev" 写道: > &

Re: add custom environment variable in bash source code

2022-08-17 Thread Alex fxmbsw7 Ratchev
maybe just 'eval "declare -gx var=value"' in bash.c code On Wed, Aug 17, 2022, 17:53 Chet Ramey wrote: > On 8/16/22 10:09 PM, b1431736...@163.com wrote: > > > Bash Version: 5.1 > > Patch Level: 16 > > Release Status: release > > > > Description: > > excuse me, how can I join the custom

Re: Performances comparission between 5.1 and 5.2.

2022-08-15 Thread Alex fxmbsw7 Ratchev
On Mon, Aug 15, 2022, 21:42 Eduardo Bustamante wrote: > On Mon, Aug 15, 2022 at 10:09 AM Greg Wooledge wrote: > > > On Mon, Aug 15, 2022 at 07:05:49PM +0200, felix wrote: > > > Description: > > > Trying some script under 5.2 beta, rc1 and rc2, I was surprised > by > > execution time. > >

Re: Performances comparission between 5.1 and 5.2.

2022-08-15 Thread Alex fxmbsw7 Ratchev
catastrophal numbers, .. On Mon, Aug 15, 2022, 19:06 felix wrote: > Configuration Information: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc > Compilation CFLAGS: -g -O2 > uname output: Linux medium 5.10.0-12-amd64 #1 SMP Debian 5.10.103-1 > (2022-03-07) x86_64 GNU/Linux > Machine Type:

Re: Revisiting Error handling (errexit)

2022-07-08 Thread Alex fxmbsw7 Ratchev
On Fri, Jul 8, 2022, 12:44 Koichi Murase wrote: > 2022年7月8日(金) 19:29 Alex fxmbsw7 Ratchev : > > > > ls -l /production/path | mail -s "all-good" not...@company.com > || > > > > true# Not critical > > > > > > > small side

Re: Revisiting Error handling (errexit)

2022-07-08 Thread Alex fxmbsw7 Ratchev
On Fri, Jul 8, 2022, 12:23 Oğuz wrote: > 8 Temmuz 2022 Cuma tarihinde Yair Lenga yazdı: > > > > Practical Example - real life. A job has to copy 3 critical data files. > It > > then sends notification via email (non-critical). > > > > #! /bin/bash > > set -o errfail > > function copy-files { >

Re: [Unknown error when running a simple bash script]

2022-07-04 Thread Alex fxmbsw7 Ratchev
On Mon, Jul 4, 2022, 18:07 wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc > Compilation CFLAGS: -g -O2 -flto=auto -ffat-lto-objects -flto=auto > -ffat-lto-objects -fstack-protector-strong -Wformat

Re: executes statement after "exit"

2022-04-16 Thread Alex fxmbsw7 Ratchev
dude u didnt get, in your example : is already the cmd therenis no 'exit cmd' in your code only exit as arg to : On Fri, Apr 15, 2022, 20:36 Frank Heckenbach wrote: > > > #!/bin/bash > > > : $((08 + 0)); exit > > > echo "Should not get here." > > > > It never executes `exit'. > > > > The

Re: Bash regexp parsing would benefit from safe recursion limit

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022 at 7:47 PM Martin Schulte wrote: > Hello Willi! > > > Fix: > > Count the stack frames during recursive parsing and emit error before > stack > > resources are entirely consumed. > > What exactly should happen and what is the benefit of this solution? > i guess it wont

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 16:58 Greg Wooledge wrote: > On Wed, Mar 30, 2022 at 04:52:16PM +0200, Alex fxmbsw7 Ratchev wrote: > > cool mate i halfway understand but great peaceful explaintion :) > > The most important thing here is that zombies are mostly harmless. > They aren'

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 16:15 Chet Ramey wrote: > On 3/30/22 1:40 AM, Alex fxmbsw7 Ratchev wrote: > > i do > > > > wpa_supplicant -i"$if" -c<( printf %s\\n \ > > 'network={' "ssid=\"$ssid\"" "psk=\"$pass\"" '}' >

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 13:53 Andreas Schwab wrote: > On Mär 30 2022, Greg Wooledge wrote: > > > If it turns out that wpa_supplicant is the parent, then that's the > > responsible party, and that's where you should send your bug reports. > > Processes don't know about process substitutions set up

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 13:30 Greg Wooledge wrote: > On Wed, Mar 30, 2022 at 07:40:22AM +0200, Alex fxmbsw7 Ratchev wrote: > > i do > > > > wpa_supplicant -i"$if" -c<( printf %s\\n \ > > 'network={' "ssid=\"$ssid\"" "psk=\"$

Re: forwarded weirdness report

2022-03-29 Thread Alex fxmbsw7 Ratchev
wrote: > > On Mar 30, 2022, at 1:37 AM, Alex fxmbsw7 Ratchev > wrote: > > > > your default of not allowing is weird > > > > seems 'allowing alias foreworders to speak' not good to you ? > > You're misrepresenting what I said and what Chris said. Read >

defuncted printf process when using wpa_supplicant

2022-03-29 Thread Alex fxmbsw7 Ratchev
i do wpa_supplicant -i"$if" -c<( printf %s\\n \ 'network={' "ssid=\"$ssid\"" "psk=\"$pass\"" '}' ) & { sleep 3 ; dhclient "$if" ; } & which is simply wpa_supplicant -iiface -c<( conf file printing ) it since years resuts in such : i think before it said printf defuncted root 1528 0.0

Re: forwarded weirdness report

2022-03-29 Thread Alex fxmbsw7 Ratchev
your default of not allowing is weird seems 'allowing alias foreworders to speak' not good to you ? its norma; see peng not one THANK YOU and still unfriendly On Wed, Mar 30, 2022 at 7:35 AM Lawrence Velázquez wrote: > > On Mar 29, 2022, at 8:26 AM, Chris Elvidge > wrote: > > > > On

Re: forwarded weirdness report

2022-03-29 Thread Alex fxmbsw7 Ratchev
ignorance priest ? On Tue, Mar 29, 2022, 14:27 Chris Elvidge wrote: > On 28/03/2022 22:00, Greg Wooledge wrote: > > > > Or -- and I know this answer will be rejected, because it's too simple > > and sensible -- stop using aliases in scripts. > > > > > > +1 > > Or could just stop answering

Re: forwarded weirdness report

2022-03-28 Thread Alex fxmbsw7 Ratchev
On Mon, Mar 28, 2022 at 11:02 PM Greg Wooledge wrote: > On Mon, Mar 28, 2022 at 04:18:05PM -0400, Chet Ramey wrote: > > On 3/28/22 3:06 PM, Martin Schulte wrote: > > > on Mon, 28 Mar 2022 20:34:40 +0200 Alex fxmbsw7 Ratchev < > fxmb...@gmail.com> wrote: > > >

Re: forwarded weirdness report

2022-03-28 Thread Alex fxmbsw7 Ratchev
lte wrote: > > Hello, > > > > on Mon, 28 Mar 2022 20:34:40 +0200 Alex fxmbsw7 Ratchev < > fxmb...@gmail.com> wrote: > >> https://pastebin.com/raw/T7ZnFapt > >> > >> about inconsitency, about chets 'uh no bugs' > >> > >> i

Re: forwarded weirdness report

2022-03-28 Thread Alex fxmbsw7 Ratchev
well irc recalled its cause aliases expand after one newline what the outdated ... On Mon, Mar 28, 2022 at 8:34 PM Alex fxmbsw7 Ratchev wrote: > https://pastebin.com/raw/T7ZnFapt > > about inconsitency, about chets 'uh no bugs' > > ive experienced this and such x times alrea

forwarded weirdness report

2022-03-28 Thread Alex fxmbsw7 Ratchev
https://pastebin.com/raw/T7ZnFapt about inconsitency, about chets 'uh no bugs' ive experienced this and such x times already ( got better, this is not my code )

Re: parameter expansion null check fails for arrays when [*] or [@] is used

2022-03-23 Thread Alex fxmbsw7 Ratchev
there is nothing but a simple str minus str, results in null string some, internal check, to make null nothing strings marked non existing, is up to you to code, and yet such doesnt exist much i think in sh bashism On Wed, Mar 23, 2022, 12:44 Greg Wooledge wrote: > On Wed, Mar 23, 2022 at

Re: for loop over parameter expansion of array can miss resulted empty list

2022-03-21 Thread Alex fxmbsw7 Ratchev
i solve this by shopt -s nullglob On Sun, Mar 20, 2022, 22:07 Alexey via Bug reports for the GNU Bourne Again SHell wrote: > Hello. > > Machine: x86_64 > OS: linux-gnu > Compiler: gcc > Compilation CFLAGS: -g -O2 -fstack-protector-strong -Wformat > -Werror=format-security -Wall > uname output:

Re: BASH_COMMAND should be set before PS0

2022-03-19 Thread Alex fxmbsw7 Ratchev
a small cosmetic workaround fix trap 'cmd=$BASH_COMMAND' DEBUG PS1='$cmd' On Sat, Mar 19, 2022 at 6:12 PM Taqras via Bug reports for the GNU Bourne Again SHell wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc >

Re: declare -x non-exportable variable types

2022-02-25 Thread Alex fxmbsw7 Ratchev
On Fri, Feb 25, 2022 at 8:52 PM Chet Ramey wrote: > On 2/25/22 12:55 PM, Léa Gris wrote: > > Le 25/02/2022 à 16:49, Chet Ramey écrivait : > > > >> You can't export array variables, period. You can't export attributes, > >> only variable names and values. You still can't export attributes. >

Re: bash completion mangles file names with newlines

2022-02-23 Thread Alex fxmbsw7 Ratchev
besides not running newest bash On Wed, Feb 23, 2022, 17:36 Ian! D. Allen wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc > Compilation CFLAGS: -g -O2 > -fdebug-prefix-map=/build/bash-a6qmCk/bash-5.0=.

Re: bash completion mangles file names with newlines

2022-02-23 Thread Alex fxmbsw7 Ratchev
as far i know is the bash compl external and buggy i trash it since 2002 On Wed, Feb 23, 2022, 17:36 Ian! D. Allen wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc > Compilation CFLAGS: -g -O2 >

Re: 'hash foo' may fail, and would require something like 'hash /usr/bin/foo'

2022-02-22 Thread Alex fxmbsw7 Ratchev
i have observed many non on clean reproducable things over time On Tue, Feb 22, 2022, 22:00 Chet Ramey wrote: > On 2/22/22 3:38 PM, Benoit Lacelle wrote: > > bash-5.1# echo $PATH > > > > /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin > > > > bash-5.1# ls /usr/local/bin/npm > > > >

Re: Long variable value get corrupted sometimes

2022-02-16 Thread Alex fxmbsw7 Ratchev
does the data contain \0 null bytes On Wed, Feb 16, 2022 at 11:20 AM David wrote: > On Wed, 16 Feb 2022 at 19:38, Daniel Qian wrote: > > > I encountered a problem that long variable value get corrupted sometimes. > > > A UTF-8 encoded file containing a lot of Chinese characters, file size >

Re: the "-e" command line argument is not recognized

2022-02-16 Thread Alex fxmbsw7 Ratchev
On Wed, Feb 16, 2022 at 9:59 AM Andreas Schwab wrote: > On Feb 16 2022, Viktor Korsun wrote: > > > runme.sh > > #!/bin/bash > > echo $0 > > echo $1 > > echo $2 > > echo $3 > > echo $4 > > echo $5 > > echo $6 > > Don't use echo to print unknown text. Use printf instead, which can > handle this

Re: Sus behaviour when cmd string ends with single backslash

2022-02-14 Thread Alex fxmbsw7 Ratchev
i like the currently showed behavior of '\' parsed as arg no need to error .. if u meant that, .. On Mon, Feb 14, 2022 at 11:17 PM Chet Ramey wrote: > On 2/13/22 3:15 PM, vzvz...@gmail.com wrote: > > > Bash Version: 5.0 > > Patch Level: 17 > > Release Status: release > > > > Description: > > >

Re: Sus behaviour when cmd string ends with single backslash

2022-02-13 Thread Alex fxmbsw7 Ratchev
On Sun, Feb 13, 2022, 22:23 wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc > Compilation CFLAGS: -g -O2 > -fdebug-prefix-map=/build/bash-a6qmCk/bash-5.0=. -fstack-protector-strong > -Wformat -Werror=format-security

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-07 Thread Alex fxmbsw7 Ratchev
On Tue, Feb 8, 2022 at 12:09 AM Ángel wrote: > > On 2022-02-07 at 11:55 +0100, Alex fxmbsw7 Ratchev wrote: > > > > however my solution still stays > > > > you just use memory locations instead of c strings > > > > and those entries in memory are of cour

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-07 Thread Alex fxmbsw7 Ratchev
On Mon, Feb 7, 2022 at 7:45 AM Lawrence Velázquez wrote: > > On Mon, Feb 7, 2022, at 1:26 AM, Alex fxmbsw7 Ratchev wrote: > > well i saw now, printf a char of "\0" results in 0 bytes out to wc -c > > % /usr/bin/printf '\0' | wc -c >1 > > > > h

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-06 Thread Alex fxmbsw7 Ratchev
On Mon, Feb 7, 2022 at 6:19 AM Lawrence Velázquez wrote: > > On Sun, Feb 6, 2022, at 11:53 PM, Alex fxmbsw7 Ratchev wrote: > > On Mon, Feb 7, 2022 at 12:02 AM Greg Wooledge wrote: > >> There are other programming languages besides bash. Some of them can > >> stor

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-06 Thread Alex fxmbsw7 Ratchev
On Mon, Feb 7, 2022 at 3:37 AM Chet Ramey wrote: > > On 2/6/22 5:11 PM, Alex fxmbsw7 Ratchev wrote: > > i just have a small question here > > the dropping of null bytes is no friend of me and i understand you're > > there to skip it instead of process, which results in n

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-06 Thread Alex fxmbsw7 Ratchev
On Mon, Feb 7, 2022 at 12:02 AM Greg Wooledge wrote: > > On Sun, Feb 06, 2022 at 11:11:43PM +0100, Alex fxmbsw7 Ratchev wrote: > > [[ Regarding nul bytes discarded by command substitution ]] > > can't these \0 bytes be encoded at least when a utf8 locale is used as > >

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-06 Thread Alex fxmbsw7 Ratchev
a replacement sequence to null bytes i would find a solution to null bytes no i didnt understand these posts of these emails but i am just concerned about the null bytes not being dropped On Sun, Feb 6, 2022 at 11:16 PM Alex fxmbsw7 Ratchev wrote: > > im sorry i didnt realize it woul

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-06 Thread Alex fxmbsw7 Ratchev
im sorry i didnt realize it would just prefix to null byte, which uses nullbyte, so it wont work cheers On Sun, Feb 6, 2022 at 11:11 PM Alex fxmbsw7 Ratchev wrote: > > i just have a small question here > the dropping of null bytes is no friend of me and i understand you're > t

Re: Corrupted multibyte characters in command substitutions fixes may be worse than problem.

2022-02-06 Thread Alex fxmbsw7 Ratchev
i just have a small question here the dropping of null bytes is no friend of me and i understand you're there to skip it instead of process, which results in null bytes gone which is not much of an use can't these \0 bytes be encoded at least when a utf8 locale is used as \u0 instead of dropping

Re: i had a read not work..

2022-02-05 Thread Alex fxmbsw7 Ratchev
no i couldnt reproduce it when my script after long time a bit began working i tried \\n and it worked im sorry there was also when IFS=$'\1' issue i couldnt fix but that may also be code error of my fault =)) peace On Sun, Feb 6, 2022 at 2:16 AM Alex fxmbsw7 Ratchev wrote: > > we

Re: i had a read not work..

2022-02-05 Thread Alex fxmbsw7 Ratchev
well, im currently coding it as one file ( it results in same code as before ) then i can change the \0 to \n and see if it appears again then i can post thank you much On Sun, Feb 6, 2022 at 2:07 AM Greg Wooledge wrote: > > On Sun, Feb 06, 2022 at 01:43:57AM +0100, Alex fxmbsw7 Ratchev

i had a read not work..

2022-02-05 Thread Alex fxmbsw7 Ratchev
this is on a friends os x, where brew install bash and gawk, resulted in good versions i tried gawk ' print ; fflush' with a read -r varname, also read -r -d $'\n' varname it never_ returned results -d '' worked fine

Re: Incorrect alias expansion within command substitution

2022-02-05 Thread Alex fxmbsw7 Ratchev
yea sorry i accept it doesnt work .. On Sat, Feb 5, 2022, 22:31 Chet Ramey wrote: > On 2/5/22 3:54 PM, Alex fxmbsw7 Ratchev wrote: > > it would make the whole work at alias level > > alias (symbolic) 1=$(( 2=1+2 3=+ 4=1+2 5=)) > > 1 2 3 4 5 > > works > > [i

Re: Incorrect alias expansion within command substitution

2022-02-05 Thread Alex fxmbsw7 Ratchev
meant in more reasonable complicated codes they are more useufl On Sat, Feb 5, 2022 at 9:54 PM Alex fxmbsw7 Ratchev wrote: > > it would make the whole work at alias level > alias (symbolic) 1=$(( 2=1+2 3=+ 4=1+2 5=)) > 1 2 3 4 5 > works > [i wish] > > On Sat, Feb 5, 20

Re: Incorrect alias expansion within command substitution

2022-02-05 Thread Alex fxmbsw7 Ratchev
it would make the whole work at alias level alias (symbolic) 1=$(( 2=1+2 3=+ 4=1+2 5=)) 1 2 3 4 5 works [i wish] On Sat, Feb 5, 2022 at 9:46 PM Chet Ramey wrote: > > On 2/5/22 3:44 PM, Alex fxmbsw7 Ratchev wrote: > > On Sat, Feb 5, 2022 at 9:39 PM Alex fxmbsw7 Ratchev

Re: Incorrect alias expansion within command substitution

2022-02-05 Thread Alex fxmbsw7 Ratchev
On Sat, Feb 5, 2022 at 9:39 PM Alex fxmbsw7 Ratchev wrote: > > On Sat, Feb 5, 2022 at 7:55 PM Chet Ramey wrote: > > > > On 2/4/22 6:17 PM, Alex fxmbsw7 Ratchev wrote: > > > what about this viewing point > > > aliases can start, $(('s, but not end... this i

Re: Incorrect alias expansion within command substitution

2022-02-05 Thread Alex fxmbsw7 Ratchev
On Sat, Feb 5, 2022 at 7:55 PM Chet Ramey wrote: > > On 2/4/22 6:17 PM, Alex fxmbsw7 Ratchev wrote: > > what about this viewing point > > aliases can start, $(('s, but not end... this is unlogic > > Well, I don't know about `unlogic' but there's an understan

Re: Incorrect alias expansion within command substitution

2022-02-04 Thread Alex fxmbsw7 Ratchev
it seems me here the data was used as var inside $(( not as alias i tried d1 d2 d3 combination and didnt work On Sat, Feb 5, 2022 at 12:17 AM Alex fxmbsw7 Ratchev wrote: > > what about this viewing point > aliases can start, $(('s, but not end... this is unlogic > > alias -- \ &g

Re: Incorrect alias expansion within command substitution

2022-02-04 Thread Alex fxmbsw7 Ratchev
ic :) On Sat, Feb 5, 2022 at 12:11 AM Alex fxmbsw7 Ratchev wrote: > > > > On Fri, Feb 4, 2022, 23:12 Chet Ramey wrote: >> >> On 2/4/22 2:56 PM, Alex fxmbsw7 Ratchev wrote: >> >> >>> by flat non lexical text parsing, excepts for quotes but then $( >>

Re: Incorrect alias expansion within command substitution

2022-02-04 Thread Alex fxmbsw7 Ratchev
On Fri, Feb 4, 2022, 23:12 Chet Ramey wrote: > On 2/4/22 2:56 PM, Alex fxmbsw7 Ratchev wrote: > > >>> by flat non lexical text parsing, excepts for quotes but then $( > logically > >>> expands, excepts: > >>> but imho the topic here is how

Re: Incorrect alias expansion within command substitution

2022-02-04 Thread Alex fxmbsw7 Ratchev
On Fri, Feb 4, 2022 at 10:18 PM Robert Elz wrote: > > Date:Fri, 4 Feb 2022 21:06:11 +0100 > From: Alex fxmbsw7 Ratchev > Message-ID: > > > > | now changing this to dynamic eof marker > > There is no such thing. Unlikel

Re: Incorrect alias expansion within command substitution

2022-02-04 Thread Alex fxmbsw7 Ratchev
On Fri, Feb 4, 2022 at 8:56 PM Alex fxmbsw7 Ratchev wrote: > > On Fri, Feb 4, 2022 at 8:28 PM Chet Ramey wrote: > > > > On 2/4/22 2:23 PM, Alex fxmbsw7 Ratchev wrote: > > > > > > imho the example above should have resulted in error ')' > > >

Re: Incorrect alias expansion within command substitution

2022-02-04 Thread Alex fxmbsw7 Ratchev
On Fri, Feb 4, 2022 at 8:28 PM Chet Ramey wrote: > > On 2/4/22 2:23 PM, Alex fxmbsw7 Ratchev wrote: > > > > imho the example above should have resulted in error ')' > > > it would execute cat a b ) with hello till $( then rather \n and a b >

Re: Incorrect alias expansion within command substitution

2022-02-04 Thread Alex fxmbsw7 Ratchev
On Fri, Feb 4, 2022, 20:18 Chet Ramey wrote: > On 2/3/22 9:46 PM, Alex fxmbsw7 Ratchev wrote: > > > The case I had in question with the question about $( a b ) was this > > one... > > > > cat <<$( a b ) > > hello > &g

Re: Incorrect alias expansion within command substitution

2022-02-03 Thread Alex fxmbsw7 Ratchev
On Wed, Feb 2, 2022, 20:43 Robert Elz wrote: > Date:Wed, 2 Feb 2022 11:38:30 -0500 > From:Chet Ramey > Message-ID: <7c422cbb-bba8-0a57-a565-eeb115120...@case.edu> > > > | > How accurately can you reconstitute? That is, can you maintain the > | > difference

Re: Incorrect alias expansion within command substitution

2022-02-03 Thread Alex fxmbsw7 Ratchev
On Thu, Feb 3, 2022, 20:02 Chet Ramey wrote: > On 2/2/22 1:30 PM, Robert Elz wrote: > > Date:Wed, 2 Feb 2022 11:38:30 -0500 > > From:Chet Ramey > > Message-ID: <7c422cbb-bba8-0a57-a565-eeb115120...@case.edu> > > > > > >| > How accurately can you reconstitute?

Re: Incorrect alias expansion within command substitution

2022-02-03 Thread Alex fxmbsw7 Ratchev
btw u just need a two teee's there one l.int local int ome g.int for with -g and the setting for non g may not be a function On Thu, Feb 3, 2022, 22:28 L A Walsh wrote: > > > On 2022/02/03 11:02, Chet Ramey wrote: > > On 2/2/22 10:18 PM, Robert Elz wrote: > > > >> Date:Wed, 02 Feb

Re: Incorrect alias expansion within command substitution

2022-02-03 Thread Alex fxmbsw7 Ratchev
On Thu, Feb 3, 2022, 22:14 Alex fxmbsw7 Ratchev wrote: > > > On Thu, Feb 3, 2022, 20:02 Chet Ramey wrote: > >> On 2/2/22 1:30 PM, Robert Elz wrote: >> > Date:Wed, 2 Feb 2022 11:38:30 -0500 >> > From:Chet Ramey >> > Me

Re: Incorrect alias expansion within command substitution

2022-02-03 Thread Alex fxmbsw7 Ratchev
On Thu, Feb 3, 2022, 18:16 Dennis Williamson wrote: > > > On Thu, Feb 3, 2022, 11:14 AM Alex fxmbsw7 Ratchev > wrote: > >> aliases are the way not to write duplicate code >> >> > > > No, functions are. > im your dreams.. >

Re: Incorrect alias expansion within command substitution

2022-02-03 Thread Alex fxmbsw7 Ratchev
aliases are the way not to write duplicate code On Thu, Feb 3, 2022, 18:06 L A Walsh wrote: > > > On 2022/02/03 07:02, Alex fxmbsw7 Ratchev wrote: > > > > > > On Thu, Feb 3, 2022, 04:20 Robert Elz > <mailto:k...@munnari.oz.au>> wrote: > > >

Re: Incorrect alias expansion within command substitution

2022-02-03 Thread Alex fxmbsw7 Ratchev
On Thu, Feb 3, 2022, 04:20 Robert Elz wrote: > Date:Wed, 02 Feb 2022 17:18:08 -0800 > From:L A Walsh > Message-ID: <61fb2d50.7010...@tlinx.org> > > | My posix non-conformance issue has to do with bash not starting with > | aliases enabled by default in all

Re: Incorrect alias expansion within command substitution

2022-02-02 Thread Alex fxmbsw7 Ratchev
i see only two solutions as an option one option does expand aliases inside safe out of the tree the other more eval ing On Thu, Feb 3, 2022, 02:27 L A Walsh wrote: > > > On 2022/02/02 08:50, Chet Ramey wrote: > > On 2/2/22 8:25 AM, L A Walsh wrote: > > > > > >> I.e. My bash is posix compliant

Re: Incorrect alias expansion within command substitution

2022-02-02 Thread Alex fxmbsw7 Ratchev
On Wed, Feb 2, 2022, 21:59 Chet Ramey wrote: > On 2/2/22 1:40 PM, Martijn Dekker wrote: > > Op 01-02-22 om 15:23 schreef Chet Ramey: > >> Historically, bash (and ksh93) has favored the former. Just about all > the > >> other shells claiming some sort of POSIX conformance favor the latter > (all

Re: How to display parameters in a function backtrace?

2022-02-02 Thread Alex fxmbsw7 Ratchev
my fault misunderstanding then too, sorry too cheers On Wed, Feb 2, 2022, 15:52 L A Walsh wrote: > > > On 2022/02/02 06:43, Alex fxmbsw7 Ratchev wrote: > > i had gdb new version > --- > This is about looking at a backtrace of shell functions in shell > > gdb ma

Re: How to display parameters in a function backtrace?

2022-02-02 Thread Alex fxmbsw7 Ratchev
the attached text is how it looks like since newly On Wed, Feb 2, 2022 at 3:35 PM L A Walsh wrote: > > I was trying to find parameters to a function that gave an error, so > I 'turned on' (included my backtracing routine), which showed: > > ./24bc: line 46: printf: `txt=\nRed,': not a valid

Re: How to display parameters in a function backtrace?

2022-02-02 Thread Alex fxmbsw7 Ratchev
i had gdb new version and then it all displayed already all params to funcs and stuff (once seen) On Wed, Feb 2, 2022, 15:35 L A Walsh wrote: > I was trying to find parameters to a function that gave an error, so > I 'turned on' (included my backtracing routine), which showed: > > ./24bc: line

Re: Incorrect alias expansion within command substitution

2022-02-02 Thread Alex fxmbsw7 Ratchev
ive had many inconsistency with bash this regarding exoerienced On Wed, Feb 2, 2022, 15:00 L A Walsh wrote: > On 2022/01/31 20:40, Martijn Dekker wrote: > > On the latest code from the devel branch: > > GNU bash, versie 5.2.0(35)-alpha (x86_64-apple-darwin18.7.0) > > > > Reproducer script: > >

Re: Incorrect alias expansion within command substitution

2022-02-01 Thread Alex fxmbsw7 Ratchev
On Tue, Feb 1, 2022, 19:25 Alex fxmbsw7 Ratchev wrote: > you'd expand an alias if seen and then reinterpret the whats gotten also > to ( possible ) current cmdline before alias > as with multiple heredocs in complex cmds { cmd "$( < /dev/fd/4 )" "$( < /dev/fd

Re: Incorrect alias expansion within command substitution

2022-02-01 Thread Alex fxmbsw7 Ratchev
On Tue, Feb 1, 2022, 19:16 Alex fxmbsw7 Ratchev wrote: > > > On Tue, Feb 1, 2022, 19:11 Chet Ramey wrote: > >> On 2/1/22 10:23 AM, Chet Ramey wrote: >> >> > If you defer alias expansion until execution, you lose the (posix- >> > encouraged but offici

Re: Incorrect alias expansion within command substitution

2022-02-01 Thread Alex fxmbsw7 Ratchev
On Tue, Feb 1, 2022, 19:11 Chet Ramey wrote: > On 2/1/22 10:23 AM, Chet Ramey wrote: > > > If you defer alias expansion until execution, you lose the (posix- > > encouraged but officially unspecified according to the approved > > interpretation of issue 1342) ability to have aliases affect

Re: Incorrect alias expansion within command substitution

2022-02-01 Thread Alex fxmbsw7 Ratchev
works On Tue, Feb 1, 2022, 19:22 Alex fxmbsw7 Ratchev wrote: > > > On Tue, Feb 1, 2022, 19:16 Alex fxmbsw7 Ratchev wrote: > >> >> >> On Tue, Feb 1, 2022, 19:11 Chet Ramey wrote: >> >>> On 2/1/22 10:23 AM, Chet Ramey wrote: >>> >>> >

Re: Bash not escaping escape sequences in directory names

2022-01-21 Thread Alex fxmbsw7 Ratchev
maybe sub'ing them away, or making it print \\e instead \e On Fri, Jan 21, 2022, 09:24 Lawrence Velázquez wrote: > On Fri, Jan 21, 2022, at 12:22 AM, L A Walsh wrote: > > On 2022/01/18 22:31, Alex fxmbsw7 Ratchev wrote > >>> Fix: > >>> Haven't look

Re: Bash not escaping escape sequences in directory names

2022-01-20 Thread Alex fxmbsw7 Ratchev
i vote for a more generous escape en/disable option On Fri, Jan 21, 2022, 06:23 L A Walsh wrote: > On 2022/01/18 22:31, Alex fxmbsw7 Ratchev wrote > >> Fix: > >> Haven't looked deeply into the bash internals but sanitizing the > directory > >> name

Re: devel: Questions about quoting in the new replacement ${var/pat/&}

2022-01-20 Thread Alex fxmbsw7 Ratchev
i still vote for back referenceable groups yes im no .c coder wush bye idea On Thu, Jan 20, 2022, 02:48 Koichi Murase wrote: > 2022年1月20日(木) 9:39 Chet Ramey : > > It will be in bash-5.2-beta. > > Thank you for the clarification. > > > There is fairly extensive documentation in the current

Re: Bash not escaping escape sequences in directory names

2022-01-18 Thread Alex fxmbsw7 Ratchev
i wanna add only few here, one i observed and was discussed a bit that is, also in declare -p, *sometimes* control chars arent escaped in my case they were messing terminal up after -p other case other dude, its output was escaped .. On Wed, Jan 19, 2022, 04:35 Josh Harcombe wrote: >

Re: bash dislikes empty functions or flow control bodies

2022-01-18 Thread Alex fxmbsw7 Ratchev
what i meant to detail more is ; where is the cmd.. synatx err, obviously On Tue, Jan 18, 2022, 17:23 Alex fxmbsw7 Ratchev wrote: > as you may see > > e() { ; } > > and sadly > > e() { } > > is simply invalid code, as the others say its by posix sh and mr

Re: bash dislikes empty functions or flow control bodies

2022-01-18 Thread Alex fxmbsw7 Ratchev
as you may see e() { ; } and sadly e() { } is simply invalid code, as the others say its by posix sh and mr bash wont digg it i guess On Tue, Jan 18, 2022, 12:46 wrote: > Configuration Information [Automatically generated, do not change]: > Machine: x86_64 > OS: linux-gnu > Compiler: gcc >

  1   2   3   4   >