[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: I think bash logic in a loop like : while [ condition] |read somevar

From: rens
Subject: Re: I think bash logic in a loop like : while [ condition] |read somevar is flawed.
Date: Tue, 24 Dec 2013 10:16:28 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0

Mr Down,

you are  a master at evading the issue.

and therefore, i.m.h.o, completely useless as a programmer.

If you try explain your statements about scope to yourself.

you do risk to end up in a endless loop of your own making.

I wish you a merry christmas.

On 12/24/13 09:29, Chris Down wrote:
On 2013-12-24 09:25:05 +0100, rens wrote:
*read is a built in. there is no  subshell.
     $ echo "$BASHPID"; : | echo "$BASHPID"

any way, it seems then to me that even IF "read" was a subshell, the scope
of that would start and end with the read statement.
I don't know why you think that.

thus, magically read in the subshell  is making while a part of it's own
shell ???
No, the pipe is.

there is no "while|read"  command, you see.....

so "while"  also invokes a shell ? that magically can do which you think is
not possible ??
because it is then the parent, not a child, evidently ?

please explain......
The pipe creates the subshell.

there  is no read command in my path.

so, with that out of the way, what is your comment ?
What does `read` have to do with anything?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]