On 23/08/2023 02:59, Greg Wooledge wrote:
bar() {
local fd
foo {fd}>&1 1>&2 2>&${fd} {fd}>&-
}
Running this appears to gives the correct results -- outputs go to the
right places -- but it leaves the temporary FD open. The final
redirection to close it doesn't work.
At first glance
See, this is why I hate using bash extensions. So many weird corner
cases and surprises
As it turns out, the answer I gave yesterday was only partially correct.
The "pure sh" solution is fine, but I offered this bash alternative:
cmd {fd}>&1 1>&2 2>&$fd {fd}>&-
This doesn't actually wor
On Mon, Aug 21, 2023 at 09:19:00AM +0700, Max Nikulin wrote:
> On 21/08/2023 01:48, Greg Wooledge wrote:
> > Some shell features do change over time, but the significant
> > ordering of redirections has remained stable ever since the original
> > Bourne shell.
>
> An exercise that relies on order
On 21/08/2023 01:05, Felix Miata wrote:
In the most recent versions of Konsole I've started (5.27.x), the default
profile
has inexplicably been changed from /bin/bash to /bin/sh.
Is it konsole or plasma version? May it happen that /bin/sh was just
saved to your konsole config files or it is
On 21/08/2023 01:48, Greg Wooledge wrote:
Some shell features do change over time, but the significant
ordering of redirections has remained stable ever since the original
Bourne shell.
An exercise that relies on order of redirections and thus demonstrates
its importance:
Swap stderr and std
On 8/20/23 14:23, Greg Wooledge wrote:
On Sun, Aug 20, 2023 at 02:05:49PM -0400, Felix Miata wrote:
Bob Weber composed on 2023-08-20 11:04 (UTC-0400):
gene heskett wrote:
I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in Konsole. What
terminal actually uses bash for the heavy
Gene writes:
> And that order of arguments is not mentioned in the bash scripting
> manual
It isn't an argument. It's an instruction to the shell. See the
REDIRECTION section of the bash man page.
--
John Hasler
j...@sugarbit.com
Elmwood, WI USA
On Sun, Aug 20, 2023 at 02:27:38PM -0400, gene heskett wrote:
> I should have prefaced cmd with a $ sign but forgot to add it in my post,
> cmd was meant to be whatever I wanted to trace, in this case digiKam which
> is the current 8.1.0 AppImage, probably updated by now as the do that about
> mont
On 8/20/23 10:52, Cindy Sue Causey wrote:
On 8/20/23, gene heskett wrote:
I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in
Konsole. What terminal actually uses bash for the heavy lifting?
Well, I started out attempting to play along in xfce4-terminal and received:
bash: tmp/
On Sun, Aug 20, 2023 at 02:05:49PM -0400, Felix Miata wrote:
> Bob Weber composed on 2023-08-20 11:04 (UTC-0400):
>
> > gene heskett wrote:
>
> >> I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in Konsole.
> >> What
> >> terminal actually uses bash for the heavy lifting?
>
> > I
On 8/20/23 10:36, Greg Wooledge wrote:
On Sun, Aug 20, 2023 at 10:28:44AM -0400, gene heskett wrote:
I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in Konsole.
What terminal actually uses bash for the heavy lifting?
The terminal is irrelevant. This is entirely done in the shell
Bob Weber composed on 2023-08-20 11:04 (UTC-0400):
> gene heskett wrote:
>> I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in Konsole.
>> What
>> terminal actually uses bash for the heavy lifting?
> In konsole its in the settings for the profile you are using. Mine just says
>
On 8/20/23 10:28, gene heskett wrote:
I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in Konsole. What
terminal actually uses bash for the heavy lifting?
Cheers, Gene Heskett.
In konsole its in the settings for the profile you are using. Mine just says
bash not /usr/bin/bash.
On 8/20/23, gene heskett wrote:
> I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in
> Konsole. What terminal actually uses bash for the heavy lifting?
Well, I started out attempting to play along in xfce4-terminal and received:
bash: tmp/cmd.log: No such file or directory
Next I
On Sun, Aug 20, 2023 at 10:28:44AM -0400, gene heskett wrote:
> I cannot make bashes redirection (cmd 2>&1 >tmp/cmd.log) work in Konsole.
> What terminal actually uses bash for the heavy lifting?
The terminal is irrelevant. This is entirely done in the shell.
Your redirections are backwards. If
15 matches
Mail list logo