Re: Windows support

"Valeriy E. Ushakov" <[email protected]>
Newsgroups gmane.comp.type-setting.lout
Message-ID <[email protected]>
On Tue, May 10, 2011 at 06:42:39 +0100, James Mansion wrote:

> >>What was most upsetting to me really was how hard it was to see
> >>where and how the command line to execute was being built.
> >
> >Why do you need to know how the argument to system() is built internally?
> 
> Because the command to execute is wrapped in a pipeline of commands
> that are *NIX-specific.  The prooblem is wrapping around the supplied
> text in 'pipe'.

Oh, it's the first time in this thread you mention "pipe".


> If I do pipe {"dir"} the command as built is:
> 
> 	cat louti1 | dir | prg2lout -r -lC -o lout1 -elout.err
[...]
> If someone could enlighten me about how/where the command is formed, I'd
> be really grateful.

In include/cprintf

  def @Filter
  {
      # ...

      pipe @Case {
          "" @Yield {
              "prg2lout -r -lC" wantblanknumbered wantnumbered
              -i{@FilterIn} -o{@FilterOut} -e{@FilterErr}
              -t{@InitTab} -T{@InitTabWidth}
          }
          else @Yield {
              "cat" @FilterIn "|" pipe "|"
              "prg2lout -r -lC" wantblanknumbered wantnumbered
              -o{@FilterOut} -e{@FilterErr}
              -t{@InitTab} -T{@InitTabWidth}
          }
      }


> Call me old-fashioned, but I thought it should be straightforward to fix
> that with an ifdef that would work on Windows and offer a contribution.
> 
> But it did not prove straightforward to work backwards from FilterExecute,
> which (obviously) is in z40.c.

You are funny :).  It's like you try to fix a shell script, but you
don't tell anyone what your problem actually is and instead you
complain about shell sources.  Call me old-fashioned, but perhaps
clearly stating the problem and refraining from passive-agressive
undertones might actually prove to be more productive.


> >>I can't really find a polite way to describe the structure of it -
> >>its like the output from a funky source to source translator.
> >
> >If you couldn't find one, perhaps, you should have kept your opinion
> >to yourself?
> 
> Are YOU going to say that is a maintainable style?
>
> Does anyone here have a good understanding of hacking on lout core
> other than Dr Kingston?

*shrug*.  ctags, idutils and similar utilities work even better than
trying to remember the file names anyway.  And yes, I did hack on Lout
internals a bit.

Lout is basically in maintenance mode, so relative value of any
prettification churn to what is now a 20+ years old codebase is
strictly negative.

-uwe
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.