🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #75850

Re: [slrn] piping an article to an interactive external command

#75850
From: those who know me have no need o...
Date: Mon, 09 Apr 2001 14:41
27 lines
1891 bytes
<slrn9d2d9v.son.gt4556a@acmex.gatech.edu> divulged:

>Correct me if I'm wrong, but to my knowledge, it is not possible with
>mutt and slrn to feed a mail to an external program that is then
>executed interactively. (I checked the last time in fall of last year.)

how would you suggest it be done?  

most programs that you would want to use as the terminus of a pipe will
be reading the article on stdin.  yet if they are supposed to be
interactive they expect the user's keyboard to be connected to stdin. 
how would the program know when mutt/slrn switched stdin from one to the
other (so that it could switch from non-interactive to interactive
behaviour)?

one program that does know what to do is urlview.  it works not because
of anything that mutt/slrn does, but because it open()s /dev/tty after
stdin reaches eof.

one way you could do it yourself is to pipe to ``cat - /dev/tty | cmd''
-- where "cmd" is the partly non-interactive and partly interactive
program to execute.  how it will know when to switch is beyond me, i.e.,
it will probably fail miserably.

-- 
okay, have a sig then
Technical Details
Message-ID: <td3ihg4pmpecd0@news.supernews.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!supernews.google.com!sn-xit-03!sn-post-01!supernews.com!news.supernews.com!not-a-real-address
References: <slrn9d2d9v.son.gt4556a@acmex.gatech.edu>

Show Full Headers
Complete Article Headers
Message-ID: <td3ihg4pmpecd0@news.supernews.com>
Subject: Re: [slrn] piping an article to an interactive external command
Date: Mon, 09 Apr 2001 14:41:52 -0000
From: not-a-real-address@usa.net (those who know me have no need of my name)
References: <slrn9d2d9v.son.gt4556a@acmex.gatech.edu>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!supernews.google.com!sn-xit-03!sn-post-01!supernews.com!news.supernews.com!not-a-real-address
Newsgroups: news.software.readers
Organization: earthfriends
User-Agent: slrn/0.9.6.3 (Linux)
X-Complaints-To: newsabuse@supernews.com
Lines: 26