Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Parse apache error_log
- X-seq: zsh-users 20176
- From: zzapper <david@xxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Re: Parse apache error_log
- Date: Fri, 1 May 2015 21:50:45 +0000 (UTC)
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- Organization: Your Company
- References: <XnsA48DA9D8816E2davidrayninfocouk@80.91.229.13> <20150501220311.6f101a62@ntlworld.com>
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx> wrote in
news:20150501220311.6f101a62@xxxxxxxxxxxx:
> On Fri, 1 May 2015 15:41:37 +0000 (UTC)
>
> Well, you *could* do this...
>
> log=wherever
> fgrep -h "$(tail -1 $log | sed 's/^\[\([^]]*\)\].*/\1/')" $log
>
> pws
>
Yep Does the job.
--
zzapper
https://twitter.com/dailyzshtip
---
This email has been checked for viruses by Avast antivirus software.
http://www.avast.com
Messages sorted by:
Reverse Date,
Date,
Thread,
Author