time program does not accept arguments

Bug #593199 reported by basicxman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
time (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Binary package hint: time

Ubuntu Release: 10.04
Kernel Version: Linux-2.6.32-22-generic
Package Version: 1.7-23build1
Repository: http://us.archive.ubuntu.com/ubuntu/ lucid/main

The `time` command will not accept arguments.

For example,

~$ time -f "%E" nslookup google.com
-f: command not found

real 0m0.184s
user 0m0.140s
sys 0m0.030s

~$

`time`s man page clearly specifies -f is a valid argument and there is even an example with the following syntax,
~$ time -f "%E real,%U user,%S sys" ls -Fs

Something like this should have returned only the formatted value.
~time -f "%E" ls
<ls return>

0m0.184s

---
Using `time` without parameters gives proper return values.

Revision history for this message
basicxman (minirobotics) wrote :
Revision history for this message
Dave Gilbert (ubuntu-treblig) wrote :

There are two things called 'time'.
The /usr/bin/time program is what the manual page refers to, however some shells have their own built in time that is simpler;
bash has one that doesn't understand the -f

In bash if you do help time it will give you the details of it's time; if you wish to use the other time make sure always to use /usr/bin/time

Dave

Changed in time (Ubuntu):
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.