Date archives: November 16th, 2009

Timing command line functions

Yet another basic command line tool that is awesome:

time

This lets you do a quick and dirty profile on some code you’re executing.

Basic Usage

time <command>

This will execute the command and put out a summary detailing how long the command took in total, how long it was tied up in actual execution, and how long it was tied up in system overhead:

real	0m0.031s
user	0m0.004s
sys	0m0.023s

Another nifty function that does one thing and one thing only, but does it well. Thanks Unix philosophy!