Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #15971

Re: bash 5.0.11 – Output not redirected

From Eli Schwartz <eschwartz@archlinux.org>
Newsgroups gnu.bash.bug
Subject Re: bash 5.0.11 – Output not redirected
Date 2020-02-26 11:59 -0500
Message-ID <mailman.1593.1582736370.2412.bug-bash@gnu.org> (permalink)
References <CAM_8-Ci8K6ZbYLE=sLicsVpeDod4RP6zhKs+QUKNVqRV8m65cQ@mail.gmail.com> <20200226154817.GD845@eeg.ccf.org> <17434a65-6f23-d323-f21c-8f6dc5e04553@archlinux.org>

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

On 2/26/20 10:48 AM, Greg Wooledge wrote:
> If you're trying to pre-populate the input buffer of a shell in a newly
> launched terminal emulator, you're about to go down some very deep
> rabbit holes.  I suggest you look at tmux or screen.  Those may have
> some of the features you're looking for, if my guess is on target.

A simpler solution if you (rhet.) just want to run a command
automatically in gnome-terminal and then wait for more commands, is,
instead of starting "bash" (or $SHELL) by default, specify that
gnome-terminal should run the command:

bash --rcfile <(cat ~/.bashrc; echo "some_commands")

That would run "some_commands" as part of the shell initialization,
though it wouldn't wait for confirmation or line editing and it wouldn't
print what you're running without also doing some explicit echo/printf
or set -x.

Kind of a confusing way to do things, but it could get the job done.

-- 
Eli Schwartz
Arch Linux Bug Wrangler and Trusted User

Back to gnu.bash.bug | Previous | Next | Find similar


Thread

Re: bash 5.0.11 – Output not redirected Eli Schwartz <eschwartz@archlinux.org> - 2020-02-26 11:59 -0500

csiph-web