Austin Group Defect Tracker

Aardvark Mark III


Viewing Issue Simple Details Jump to Notes ] Issue History ] Print ]
ID Category Severity Type Date Submitted Last Update
0000169 [1003.1(2008)/Issue 7] Shell and Utilities Editorial Enhancement Request 2009-10-15 15:44 2009-11-05 16:54
Reporter wpollock View Status public  
Assigned To ajosey
Priority normal Resolution Future Enhancement  
Status Resolved  
Name Wayne Pollock
Organization
User Reference
Section date
Page Number NA
Line Number NA
Interp Status ---
Final Accepted Text Note: 0000283
Summary 0000169: date utility needs ``%s''
Description There is currently no simple way, short of writing a C program, to obtain the "seconds since the epoch", commonly referred to as "Unix time". I would like to request the date utility be extended to include an additional conversion specification of:

 %s seconds since 1970-01-01 00:00:00 UTC (see XBD Seconds Since the Epoch)
Desired Action Add the new conversion specifier
Tags No tags attached.
Attached Files

- Relationships

-  Notes
(0000262)
geoffclare (manager)
2009-10-16 09:07
edited on: 2009-10-16 09:12

If the proposed change to date is made, we should also add %s to
strftime() and strptime() for consistency.

Although it would be kind-of redundant for those functions (being
equivalent to mktime() and localtime() respectively, plus conversion
to/from a string) it would be usable in user-supplied/configured
format strings.

The detailed changes needed would be ...
After line 82902 add:

    %s   Seconds since 1970-01-01 00:00:00 UTC as a decimal number
         (see [xref to XBD 4.15 Seconds Since the Epoch])

Cross-volume changes to XSH:

After page 2009 line 63596 section strftime, add:

[CX]s    Replaced by the number of seconds since 1970-01-01 00:00:00 UTC
         as a decimal number (see [xref to XBD 4.15 Seconds Since the
         Epoch]). [all members, as if by a call to mktime()] [/CX]

After page 2027 line 64161 section strptime, add:

    s    The number of seconds since 1970-01-01 00:00:00 UTC as a
         decimal number (see [xref to XBD 4.15 Seconds Since the
         Epoch]); leading zeros shall be permitted but shall not be
         required.


(0000283)
Don Cragun (manager)
2009-11-05 16:52

After line 82902 add:

    %s   Seconds since the Epoch as a decimal number
         (see [xref to XBD 4.15 Seconds Since the Epoch])

Cross-volume changes to XSH:

After page 2009 line 63596 section strftime, add:

[CX]s    Replaced by the number of seconds since the Epoch
         as a decimal number (see [xref to XBD 4.15 Seconds Since the
         Epoch]). [all members, as if by a call to mktime()] [/CX]

After page 2027 line 64161 section strptime, add:

    s    The number of seconds since the Epoch as a
         decimal number (see [xref to XBD 4.15 Seconds Since the
         Epoch]); leading zeros shall be permitted but shall not be
         required.

- Issue History
Date Modified Username Field Change
2009-10-15 15:44 wpollock New Issue
2009-10-15 15:44 wpollock Status New => Under Review
2009-10-15 15:44 wpollock Assigned To => ajosey
2009-10-15 15:44 wpollock Name => Wayne Pollock
2009-10-15 15:44 wpollock Section => date
2009-10-15 15:44 wpollock Page Number => NA
2009-10-15 15:44 wpollock Line Number => NA
2009-10-15 15:45 wpollock Issue Monitored: wpollock
2009-10-16 09:07 geoffclare Note Added: 0000262
2009-10-16 09:07 geoffclare Note Edited: 0000262
2009-10-16 09:12 geoffclare Note Edited: 0000262
2009-11-05 16:51 msbrown Interp Status => ---
2009-11-05 16:51 msbrown Resolution Open => Future Enhancement
2009-11-05 16:52 Don Cragun Note Added: 0000283
2009-11-05 16:54 Don Cragun Final Accepted Text => Note: 0000283
2009-11-05 16:54 Don Cragun Status Under Review => Resolved


Mantis 1.1.6[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker