Path: ...!feeds.phibee-telecom.net!3.eu.feeder.erje.net!feeder.erje.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Janis Papanagnou Newsgroups: comp.unix.shell Subject: Re: Different variable assignments Date: Sat, 19 Oct 2024 14:52:01 +0200 Organization: A noiseless patient Spider Lines: 23 Message-ID: References: <83y12u2xyt.fsf@helmutwaitzmann.news.arcor.de> MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Injection-Date: Sat, 19 Oct 2024 14:52:02 +0200 (CEST) Injection-Info: dont-email.me; posting-host="27fda3d49159bc2239fd5bfbb5f05d8d"; logging-data="4086812"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19pKfgO/hAtcCzBR2/KDdFE" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 Cancel-Lock: sha1:FqQxbpqKNy11aiYnxhCBeuohAQQ= In-Reply-To: X-Enigmail-Draft-Status: N1110 Bytes: 1988 On 19.10.2024 13:45, Kenny McCormack wrote: > In article , > Lawrence D'Oliveiro wrote: >> On Fri, 11 Oct 2024 22:50:10 +0200, Frank Winkler wrote: >> >>> ... but it still doesn't solve the issue that I need the result to be >>> visible in the parent shell. >> >> coproc { uname -sr; } >> read -u ${COPROC[0]} var3 >> wait $COPROC_PID >> echo $var3 > > I'm actually a fan of "coproc" in bash, and I use it in my scripting, but I > think it is overkill in most cases. [...] Also, if above code is how to use co-processes in Bash, I consider that extremely clumsy (if compared to, say, Ksh). (Mileages may vary, of course.) Janis