Re: recognizing an xterm running only bash from the CLI
On Sun, Aug 10, 2025 at 11:28:08PM -0400, Greg Wooledge wrote:
<snip>
> I'm having trouble understanding what you're saying here. When you
> say "copy my entry", does that mean you want to type stuff on one
> terminal, and have it appear on the other terminal?
Sorry I wasn't clear, I'll try again.
I've defined to9 () { echo "$1" > /dev/tty9 } to be used from an xterm.
I'd like to have a similar function toX() to be used on a virtual
terminal that would print some text on the xterm running only bash
but that xterm varies which /dev/pts/? it's running on and so far
I've not found a way without manually going into X and entering 'tty'
on that xterm to find out which /dev/pts to direct an echo to.
If I can learn how to determine which /dev/pts/? is running only bash
and not mc or something else then I can write toX() to just work.
Thanks,
Mike
--
Take your campaign contribution, and send it to the Red Cross, and let
the election be decided on its merit.
- Will Rogers
Reply to: