timethis commandname
Where:
You can also specify the arguments for the command. For example:
timethis net use x: \\server\share /user:billybob
runs net use x: \\server\share /user:billybob and report how long it took.
Quotation marks around the command are required when the command involves redirection via <, >, >>, or |, for example. Quotation marks ensure that the redirection is applied to the command being timed, rather than the timethis command itself. For example:
timethis "dir > dirlist.txt"