[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] Here documents and CRLF



Hi Thomas!

On Fri, Jun 11, 1999 at 10:17:20PM +0200, Thomas Binder wrote:
> Hi!
> 
> On Fri, Jun 11, 1999 at 07:59:45PM +0200, Guido Flohr wrote:
> > So, what happens?  Whenever I hit the return key I actually send CRLF,
> > right?
> 
> Have you tried what stty -a reports?
> 
> Check and compare these values:
> 
>      onlcr (-onlcr)
>            map (do not map) NL to CR-NL on output.
>      ocrnl (-ocrnl)
>            map (do not map) CR to NL on output.
>      onocr (-onocr)
>            do not (do) output CRs at column zero.
>      onlret (-onlret)
>            on the terminal NL performs (does not perform) the CR function.
> 
> If necessary, change one of these settings and compare the result(s).

I actually should change the input settings.  Output doesn't go to a
terminal.

Anyway, stty -a reports

... -inlcr -igncr icrnl

What I need is to translate CRLF on input to LF.  So what should I say to
stty to get that?  On the other hand, when I telnet to my MiNT box from a
machine without that CRLF nuisance I actually shouldn't do any
translations, should I?  Or is pressing the <RETURN> key always equivalent
to CRLF, no matter what operating system I run?

Zut, alors:

bash$ stty -igncr
bash$ echo $?
0
bash$ stty igncr
stty: standard input: unable to perform all requested operations
bash$

On my linux box "stty igncr" works but it leaves me with a terminal that
is unoperable because hitting RETURN has no effect at all (i. e. there is
no way to type in any command).

BTW, my stty doesn't report any of the [-]o* flags you mentioned (I
haven't omitted them on purpose).

Ciao

Guido
-- 
http://stud.uni-sb.de/~gufl0000
mailto:gufl0000@stud.uni-sb.de