in reply to How to use pty for both STDERR AND STDOUT in IPC::Run, while doing something different with each?

I'm sorry, there's no way I can read that code. Do you have something against white-space? Perhaps you could give perltidy a try? And while you're at it, how about a "use strict"?

-sam

  • Comment on Re: How to use pty for both STDERR AND STDOUT in IPC::Run, while doing something different with each?

Replies are listed 'Best First'.
Re^2: How to use pty for both STDERR AND STDOUT in IPC::Run, while doing something different with each?
by OfficeLinebacker (Chaplain) on May 22, 2006 at 19:12 UTC
    I compressed the part where I set up and open the log file so as so reduce screen RE; shall I add some blank lines or remove the context?

    As far as using strict; will that help my particular problem?

    _________________________________________________________________________________
    Without me, it's just aweso

      Yes, you should make code you post here maximally readable and as short as possible. I bet lots of people that could have helped you skipped right past your post when they saw that god-awful block of code.

      I don't know if "use strict" will solve your problem, but it certainly can't hurt!

      -sam

        Whoops, just saw this. Seems like "maximally readable" and "as short as possible" are conflicting. I think I will just edit out everything but the run() part and leave it at that.

        _________________________________________________________________________________
        Without me, it's just aweso

Re^2: How to use pty for both STDERR AND STDOUT in IPC::Run, while doing something different with each?
by OfficeLinebacker (Chaplain) on May 22, 2006 at 19:59 UTC
    better?

    _________________________________________________________________________________
    Without me, it's just aweso

      Moderately. That run() line is still nuts and you've got a lot of lines with far too few spaces in the top chunk. But's definitely a lot more readable now.

      -sam

        Well, how would you structure 1) the run line and 2) the program in general? Go ahead, the node is your oyster..

        _________________________________________________________________________________
        Without me, it's just aweso