Last line of file/Perl
Bill Warner
plug-discuss@lists.plug.phoenix.az.us
14 Nov 2002 15:24:05 -0700
yea nad cant you do
use Shell qw(tail);
or something like that. I used it once to gain perl syntax access ot
shell commands
Bill
On Thu, 2002-11-14 at 13:56, Voltage Spike wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On Thursday, November 14, 2002, at 01:49 PM, Mike Starke wrote:
>
> > On Thu, Nov 14, 2002 at 12:41:50PM -0800, Matt Alexander wrote:
> > /_tail -1 somefile ?
> > /_
> >
> > I was actually looking for a Perl solution without having to read
> > through the entire file.
>
> I suppose:
>
> $results = `tail -n1 $somefile`;
>
> isn't good enough?
>
> - --
> Voltage
> Spike
> ,,,
> (. .)
> - --ooO-(_)-Ooo--
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.0.7 (Darwin)
>
> iD8DBQE91A3spNoctRtUIRQRAlZFAJ9RhoYm1SSEvWW3B4aSDpdCzPlk+gCZAaKl
> RvSN6HKfn2G7rbNKvUjq6uQ=
> =wD2D
> -----END PGP SIGNATURE-----
>
> ---------------------------------------------------
> PLUG-discuss mailing list - PLUG-discuss@lists.plug.phoenix.az.us
> To subscribe, unsubscribe, or to change you mail settings:
> http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss
--
Bill Warner <wwarner@direct-alliance.com>
Direct Alliance