Mailinglist Archive: opensuse (1318 mails)

< Previous Next >
Re: [opensuse] BASH - while read; howto read last line in file without blank line at end?
  • From: Anders Johansson <ajohansson@xxxxxxx>
  • Date: Sat, 1 Nov 2008 14:41:30 +0100
  • Message-id: <200811011441.30448.ajohansson@xxxxxxx>
On Saturday 01 November 2008 04:51:43 David C. Rankin wrote:
If there is no blank line at the end of the file, the while loop reads
the
"oss-src" line, but does not read the "lastline". If there is a blank line
at the end, it reads "lastline" just fine. What is the trick to be able to
read the last line of the repos file regardless of whether there is a blank
at the end or not?

Works just fine here on 11.0, with or without {}

Anders

--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups
References