Unix timestamp
    Jonathan Chen 
    jonc at chen.org.nz
       
    Tue Sep 23 02:58:38 PDT 2003
    
    
  
On Tue, Sep 23, 2003 at 06:07:50AM +0100, Jez Hancock wrote:
> Is there a native FreeBSD shell util for returning the time in seconds
> since the Unix epoch?  date(1) doesn't seem to do this, only the
> converse with the -r switch:
> 
> [6:05:51] munk at users /home/munk# date -r "1064293551"
> Tue Sep 23 06:05:51 BST 2003
> 
> Just curious - I ended up making a simple C app that does the job.
This works for me:
    ~,9:57pm> date '+%s'
    1064311041
Cheers.
-- 
Jonathan Chen <jonc at chen.org.nz>
----------------------------------------------------------------------
                 When you don't know what you are doing, do it neatly.
    
    
More information about the freebsd-questions
mailing list