Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

<moshez> ok, I will not marry Jo-Con-El's cow.


devel / comp.lang.tcl / Re: Gui to background application

SubjectAuthor
* Gui to background applicationWilliam Giddings
`- Gui to background applicationRich

1
Gui to background application

<3423b375-63bc-48c3-9ff1-6c62fe8f3950n@googlegroups.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=12642&group=comp.lang.tcl#12642

  copy link   Newsgroups: comp.lang.tcl
X-Received: by 2002:a05:620a:2401:b0:77f:3b9c:682c with SMTP id d1-20020a05620a240100b0077f3b9c682cmr177863qkn.13.1703421264842;
Sun, 24 Dec 2023 04:34:24 -0800 (PST)
X-Received: by 2002:a05:620a:46a7:b0:781:123c:498d with SMTP id
bq39-20020a05620a46a700b00781123c498dmr126527qkb.11.1703421264556; Sun, 24
Dec 2023 04:34:24 -0800 (PST)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!border-2.nntp.ord.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.tcl
Date: Sun, 24 Dec 2023 04:34:24 -0800 (PST)
Injection-Info: google-groups.googlegroups.com; posting-host=188.28.57.153; posting-account=hVWNxAoAAAAH_bNIIcXChX_K0XNgZtnS
NNTP-Posting-Host: 188.28.57.153
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <3423b375-63bc-48c3-9ff1-6c62fe8f3950n@googlegroups.com>
Subject: Gui to background application
From: wjgiddi...@googlemail.com (William Giddings)
Injection-Date: Sun, 24 Dec 2023 12:34:24 +0000
Content-Type: text/plain; charset="UTF-8"
Lines: 8
 by: William Giddings - Sun, 24 Dec 2023 12:34 UTC

Fellow Tclers!

I want to create a ui to communicate with an active Linux shell application. The application takes input from stdin and outputs to stdout.

How can I capture the content of stdout and write to stdin such that the application sends and receives the correct responses?

Many thanks and seasons best wishes to all!

William

Re: Gui to background application

<um9jdo$2k7pu$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=12647&group=comp.lang.tcl#12647

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ric...@example.invalid (Rich)
Newsgroups: comp.lang.tcl
Subject: Re: Gui to background application
Date: Sun, 24 Dec 2023 15:40:40 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 20
Message-ID: <um9jdo$2k7pu$1@dont-email.me>
References: <3423b375-63bc-48c3-9ff1-6c62fe8f3950n@googlegroups.com>
Injection-Date: Sun, 24 Dec 2023 15:40:40 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="5a26340f68fdaff48c439a20b2ceea61";
logging-data="2760510"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX188UgyBNbmFFDqgtJ/7WL2S"
User-Agent: tin/2.6.1-20211226 ("Convalmore") (Linux/5.15.139 (x86_64))
Cancel-Lock: sha1:hLbLhYYUTYJtcj2gIamVS570zXo=
 by: Rich - Sun, 24 Dec 2023 15:40 UTC

William Giddings <wjgiddings@googlemail.com> wrote:
> Fellow Tclers!
>
> I want to create a ui to communicate with an active Linux shell
> application. The application takes input from stdin and outputs to
> stdout.
>
> How can I capture the content of stdout and write to stdin such that
> the application sends and receives the correct responses?

Read the 'open' manpage, specifically the section about "command
pipelines".

Note that you will most likely want to set line buffering and to make
use of non-blocking event driven I/O to the channel connected to the
shell application.

Alternately, load the 'expect' extension
(https://core.tcl-lang.org/expect/index) and use expects tools to talk
to the shell application.

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor