Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: tcsh set time equivalent
- X-seq: zsh-users 16461
- From: Dan Nelson <dnelson@xxxxxxxxxxxxxxx>
- To: Mikael Magnusson <mikachu@xxxxxxxxx>
- Subject: Re: tcsh set time equivalent
- Date: Sat, 1 Oct 2011 21:07:52 -0500
- Cc: Renato Botelho <rbgarga@xxxxxxxxx>, zsh-users@xxxxxxx
- In-reply-to: <CAHYJk3SqK7hw=sF-50+Xc5=6PDsSjhdWO+NQpsiNL9Wrhf5DhA@mail.gmail.com>
- 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
- References: <CAESiWk=f2GT=vuSCxDiYfGDG5-f5z_COD30-wT-Dd8Vyu7zUWg@mail.gmail.com> <CAHYJk3SqK7hw=sF-50+Xc5=6PDsSjhdWO+NQpsiNL9Wrhf5DhA@mail.gmail.com>
In the last episode (Oct 01), Mikael Magnusson said:
> On 30 September 2011 23:58, Renato Botelho <rbgarga@xxxxxxxxx> wrote:
> > I used to have a configuration on tcsh:
> >
> > set time=(60 "\
> > Time spent in user mode (CPU seconds) : %Us\
> > Time spent in kernel mode (CPU seconds) : %Ss\
> > Total time : %Es\
> > CPU utilisation (percentage) : %P\
> > Times the process was swapped : %W\
> > Times of major page faults : %F\
> > Times of minor page faults : %R")
> >
> > With this, if a command that took over 60s to be executed, this summary
> > was showed after.
> >
> > Is there any equivalent function on zsh?
>
> There's REPORTTIME (just assign a number to it), but it measures cpu time,
> not wall clock.
tcsh measures CPU time too. Renato, you'll also want to set TIMEFMT to your
output format string; zsh understands all the escape sequences in your
string, so you can use it unmodified if you want, or add more.
--
Dan Nelson
dnelson@xxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author