Date and time formats


This application uses ANSI standard formats for describing dates and time.  You may use the formatting codes to create date and time formats:

Code Replaced by
%a abbreviated weekday name, e.g., "Mon"
%A full weekday name, e.g. "Lundi"
%b abbreviated monthname, e.g. "Jul"
%B full month name, e.g. "Fevrier"
%c locale-specific date and time
%d day of the month as a decimal integer (01-31)
%H the hour (24-hour clock) as a decimal integer (00-23)
%I the hour (12-hour clock) as a decimal integer (00-12)
%j day of the year as a decimal number (001-366)
%m month as a decimal number (01-12)
%M minute as a decimal number (00-59)
%p the local's equivalent of AM/PM designation for 12-hour clock
%S second as a decimal number (00-59)1
%U week number of the year (00-53)2
%w weekday as a decimal number (0-6, Sunday = 0)
%W week number of the year3
%x local-specific date
%X local-specific time
%y year without century as a decimal number (00-99)
%Y year with century as a decimal number, e.g., 1952
%z time zone name or abbreviation, or none if not known
%% a single %


1 Allows for up to 2 leap-seconds (60 and 61).
2 Week number 1 has the first Sunday; previous days are week 0.
3 Week number 1 has the first Monday; previous days are week 0.

See also

Set date and time preferences
Date command
Time command