Re: Capturing only STDERR with Capture::Tiny?

Gabor Szabo <[email protected]>
Newsgroups gmane.comp.lang.perl.quality-assurance
Message-ID <CABe4FJD_cOXS9KbryK11cUqHE2Ljc_4_Ey6dA6iqKVOmFFeSNg@mail.gmail.com>
On Wed, Nov 30, 2011 at 12:16 PM, David Golden <[email protected]> wrote:
> On Tue, Nov 29, 2011 at 11:25 PM, Gabor Szabo <[email protected]> wrote:
>> What is your suggestion to solve this?
>> Does a request for such feature in Capture::Tiny sound reasonable?
>
> It's reasonable and has been requested before:
>
> https://rt.cpan.org/Public/Bug/Display.html?id=60515
>
> I haven't found the tuits to dive back into the mess and implement it.
>  To some extent, I'm trying to keep this "Tiny" and not implement
> every possible variation of capture that people might like.  To
> another extent, I've not decided on an API that I like for doing the
> variations.  (I cringed when I added 'capture_merged').

For now the way I used works. I pushed it out to Github
https://github.com/szabgab/Term-ProgressBar
and sent a mail to Martyn J. Pearce.
I hope he will answer soon, though he has not uploaded
anything for almost a year now.

Regarding the API,

What about something like:
capture {}, {stdout => 'none', stderr => 'capture'};

Where actually => 'capture' is the default and the available values would be
'none', 'tee', 'capture'

regards
   Gabor
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.