Tizen 2.0 Release
[external/tizen-coreutils.git] / man / date.1
1 .\" DO NOT MODIFY THIS FILE!  It was generated by help2man 1.35.
2 .TH DATE "1" "March 2007" "GNU coreutils 6.9" "User Commands"
3 .SH NAME
4 date \- print or set the system date and time
5 .SH SYNOPSIS
6 .B date
7 [\fIOPTION\fR]... [\fI+FORMAT\fR]
8 .br
9 .B date
10 [\fI-u|--utc|--universal\fR] [\fIMMDDhhmm\fR[[\fICC\fR]\fIYY\fR][\fI.ss\fR]]
11 .SH DESCRIPTION
12 .\" Add any additional description here
13 .PP
14 Display the current time in the given FORMAT, or set the system date.
15 .TP
16 \fB\-d\fR, \fB\-\-date\fR=\fISTRING\fR
17 display time described by STRING, not `now'
18 .TP
19 \fB\-f\fR, \fB\-\-file\fR=\fIDATEFILE\fR
20 like \fB\-\-date\fR once for each line of DATEFILE
21 .TP
22 \fB\-r\fR, \fB\-\-reference\fR=\fIFILE\fR
23 display the last modification time of FILE
24 .TP
25 \fB\-R\fR, \fB\-\-rfc\-2822\fR
26 output date and time in RFC 2822 format.
27 Example: Mon, 07 Aug 2006 12:34:56 \fB\-0600\fR
28 .TP
29 \fB\-\-rfc\-3339\fR=\fITIMESPEC\fR
30 output date and time in RFC 3339 format.
31 TIMESPEC=`date', `seconds', or `ns' for
32 date and time to the indicated precision.
33 Date and time components are separated by
34 a single space: 2006\-08\-07 12:34:56\-06:00
35 .TP
36 \fB\-s\fR, \fB\-\-set\fR=\fISTRING\fR
37 set time described by STRING
38 .TP
39 \fB\-u\fR, \fB\-\-utc\fR, \fB\-\-universal\fR
40 print or set Coordinated Universal Time
41 .TP
42 \fB\-\-help\fR
43 display this help and exit
44 .TP
45 \fB\-\-version\fR
46 output version information and exit
47 .PP
48 FORMAT controls the output.  The only valid option for the second form
49 specifies Coordinated Universal Time.  Interpreted sequences are:
50 .TP
51 %%
52 a literal %
53 .TP
54 %a
55 locale's abbreviated weekday name (e.g., Sun)
56 .TP
57 %A
58 locale's full weekday name (e.g., Sunday)
59 .TP
60 %b
61 locale's abbreviated month name (e.g., Jan)
62 .TP
63 %B
64 locale's full month name (e.g., January)
65 .TP
66 %c
67 locale's date and time (e.g., Thu Mar  3 23:05:25 2005)
68 .TP
69 %C
70 century; like %Y, except omit last two digits (e.g., 21)
71 .TP
72 %d
73 day of month (e.g, 01)
74 .TP
75 %D
76 date; same as %m/%d/%y
77 .TP
78 %e
79 day of month, space padded; same as %_d
80 .TP
81 %F
82 full date; same as %Y\-%m\-%d
83 .TP
84 %g
85 last two digits of year of ISO week number (see %G)
86 .TP
87 %G
88 year of ISO week number (see %V); normally useful only with %V
89 .TP
90 %h
91 same as %b
92 .TP
93 %H
94 hour (00..23)
95 .TP
96 %I
97 hour (01..12)
98 .TP
99 %j
100 day of year (001..366)
101 .TP
102 %k
103 hour ( 0..23)
104 .TP
105 %l
106 hour ( 1..12)
107 .TP
108 %m
109 month (01..12)
110 .TP
111 %M
112 minute (00..59)
113 .TP
114 %n
115 a newline
116 .TP
117 %N
118 nanoseconds (000000000..999999999)
119 .TP
120 %p
121 locale's equivalent of either AM or PM; blank if not known
122 .TP
123 %P
124 like %p, but lower case
125 .TP
126 %r
127 locale's 12\-hour clock time (e.g., 11:11:04 PM)
128 .TP
129 %R
130 24\-hour hour and minute; same as %H:%M
131 .TP
132 %s
133 seconds since 1970\-01\-01 00:00:00 UTC
134 .TP
135 %S
136 second (00..60)
137 .TP
138 %t
139 a tab
140 .TP
141 %T
142 time; same as %H:%M:%S
143 .TP
144 %u
145 day of week (1..7); 1 is Monday
146 .TP
147 %U
148 week number of year, with Sunday as first day of week (00..53)
149 .TP
150 %V
151 ISO week number, with Monday as first day of week (01..53)
152 .TP
153 %w
154 day of week (0..6); 0 is Sunday
155 .TP
156 %W
157 week number of year, with Monday as first day of week (00..53)
158 .TP
159 %x
160 locale's date representation (e.g., 12/31/99)
161 .TP
162 %X
163 locale's time representation (e.g., 23:13:48)
164 .TP
165 %y
166 last two digits of year (00..99)
167 .TP
168 %Y
169 year
170 .TP
171 %z
172 +hhmm numeric timezone (e.g., \fB\-0400\fR)
173 .TP
174 %:z
175 +hh:mm numeric timezone (e.g., \fB\-04\fR:00)
176 .TP
177 %::z
178 +hh:mm:ss numeric time zone (e.g., \fB\-04\fR:00:00)
179 .TP
180 %:::z
181 numeric time zone with : to necessary precision (e.g., \fB\-04\fR, +05:30)
182 .TP
183 %Z
184 alphabetic time zone abbreviation (e.g., EDT)
185 .PP
186 By default, date pads numeric fields with zeroes.
187 The following optional flags may follow `%':
188 .TP
189 \-
190 (hyphen) do not pad the field
191 .TP
192 _
193 (underscore) pad with spaces
194 .TP
195 0
196 (zero) pad with zeros
197 .TP
198 ^
199 use upper case if possible
200 .TP
201 #
202 use opposite case if possible
203 .PP
204 After any flags comes an optional field width, as a decimal number;
205 then an optional modifier, which is either
206 E to use the locale's alternate representations if available, or
207 O to use the locale's alternate numeric symbols if available.
208 .SH AUTHOR
209 Written by David MacKenzie.
210 .SH "REPORTING BUGS"
211 Report bugs to <bug\-coreutils@gnu.org>.
212 .SH COPYRIGHT
213 Copyright \(co 2007 Free Software Foundation, Inc.
214 .br
215 This is free software.  You may redistribute copies of it under the terms of
216 the GNU General Public License <http://www.gnu.org/licenses/gpl.html>.
217 There is NO WARRANTY, to the extent permitted by law.
218 .SH "SEE ALSO"
219 The full documentation for
220 .B date
221 is maintained as a Texinfo manual.  If the
222 .B info
223 and
224 .B date
225 programs are properly installed at your site, the command
226 .IP
227 .B info date
228 .PP
229 should give you access to the complete manual.