This is the mail archive of the
cygwin@sources.redhat.com
mailing list for the Cygwin project.
Re: Newbie: read works incorrectly
- To: cygwin at cygwin dot com
- Subject: Re: Newbie: read works incorrectly
- From: Sylvain Petreolle <spetreolle at yahoo dot fr>
- Date: Wed, 22 Nov 2000 16:05:59 +0100 (CET)
--- schwarza@gdls.com a écrit : >
> The following statement:
>
> echo one two | while read line ; do
> printf '%s\r\n' $line
> done
>
> generates
>
> one
> two
>
> I would have expected
>
> one two
>
The '\r\n' statement tells to printf to inser a new
line, then remove it.
___________________________________________________________
Do You Yahoo!? -- Pour dialoguer en direct avec vos amis,
Yahoo! Messenger : http://fr.messenger.yahoo.com
--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com