Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

time(1) [opendarwin man page]

TIME(1) 						    BSD General Commands Manual 						   TIME(1)

NAME
time -- time command execution SYNOPSIS
time [-al] [-h | -p] [-o file] utility [argument ...] DESCRIPTION
The time utility executes and times the specified utility. After the utility finishes, time writes to the standard error stream, (in sec- onds): the total time elapsed, the time used to execute the utility process and the time consumed by system overhead. Available options: -a If the -o flag is used, append to the specified file rather than overwriting it. Otherwise, this option has no effect. -h Print times in a human friendly format. Times are printed in minutes, hours, etc. as appropriate. -l The contents of the rusage structure are printed as well. -o file Write the output to file instead of stderr. If file exists and the -a flag is not specified, the file will be overwritten. -p Makes time output POSIX.2 compliant (each time is printed on its own line). Some shells may provide a builtin time command which is similar or identical to this utility. Consult the builtin(1) manual page. ENVIRONMENT
The PATH environment variable is used to locate the requested utility if the name contains no '/' characters. DIAGNOSTICS
If utility could be timed successfully, its exit status is returned. If utility terminated abnormally, a warning message is output to stderr. If the utility was found but could not be run, the exit status is 126. If no utility could be found at all, the exit status is 127. If time encounters any other error, the exit status is between 1 and 125 included. SEE ALSO
builtin(1), csh(1), getrusage(2), wait(2) STANDARDS
The time utility is expected to conform to ISO/IEC 9945-2:1993 (``POSIX''). HISTORY
A time command appeared in Version 3 AT&T UNIX. BSD
June 6, 1993 BSD

Check Out this Related Man Page

PRINTENV(1)						    BSD General Commands Manual 					       PRINTENV(1)

NAME
printenv, env -- print out the environment, set and print environment SYNOPSIS
printenv [name] env [-i] [name=value ...] [utility [argument ...]] DESCRIPTION
The printenv utility prints out the names and values of the variables in the environment, with one name/value pair per line. If name is specified, only its value is printed. Some shells may provide a builtin printenv command which is similar or identical to this utility. Consult the builtin(1) manual page. The env utility executes utility after modifying the environment as specified on the command line. The option name=value specifies an envi- ronment variable, name, with a value of value. The options are as follows: -i Execute the utility with only those environment values specified. The environment inherited by env is ignored completely. If no utility is specified, env prints out the names and values of the variables in the environment, with one name/value pair per line. The env utility is sometimes useful with the ``#!'' construct (see execve(2)). The only difference between ``#!/usr/local/bin/foo'' and ``#!/usr/bin/env /usr/local/bin/foo'' is that the latter works even if /usr/local/bin/foo is itself interpreted. Using env this way also allows one to reference foo without the path, as well as set up the environment as desired. ENVIRONMENT
The env utility uses the PATH environment variable is used to locate the requested utility if the name contains no '/' characters. DIAGNOSTICS
The printenv utility exits 0 on success, and >0 if an error occurs. The env utility exits 0 on success, and >0 if an error occurs. An exit status of 126 indicates utility was found, but could not be executed. An exit status of 127 indicates utility could not be found. COMPATIBILITY
The env utility accepts the - option as a synonym for -i. SEE ALSO
csh(1), sh(1), execvp(3), environ(7) STANDARDS
The env utility conforms to IEEE Std 1003.1-2001 (``POSIX.1''). HISTORY
The printenv command appeared in 3.0BSD. BUGS
The env utility doesn't handle utility arguments with equal (``='') signs in their names, for obvious reasons. BSD
June 6, 1993 BSD
Man Page