This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: read file with windows filenames
Mark J. Reed wrote:
> For what it's worth, I've had intermittent problems with bash and
> while read loops where the loop aborts after one iteration whenever
> there's nontrivial code in the loop body, on multiple platforms, not
> just Cygwin. So this might not be a Cygwin issue. I've never been
> ble to isolate the problem enough to file a bug report, unfortunately.
Thanks to all.
The problem was a problem of this windows program attrib. /dev/null will
solve this problem. :-)
#!/bin/sh
while read -r cLine
do
echo $cLine
attrib ${cLine%%:*} "${cLine#*:}" < /dev/null
done < 2restore4
br
Matthias
--
Don't Panic
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/