chiark / gitweb /
man: document yearly and annually in systemd.time(7)
[elogind.git] / man / systemd.time.xml
index 79ebdc5..02431a5 100644 (file)
                 but when the weekday is specified it must either be
                 in the abbreviated (<literal>Wed</literal>) or
                 non-abbreviated (<literal>Wednesday</literal>) English
-                language form (case doesn't matter), and is not
+                language form (case does not matter), and is not
                 subject to the locale choice of the user. Either the
                 date, or the time part may be omitted, in which case
                 the current date or 00:00:00, resp., is assumed. The
                 <para>When parsing, systemd will also accept relative
                 time specifications. A time span (see above) that is
                 prefixed with <literal>+</literal> is evaluated to the
-                current time plus the specified
-                time span. Correspondingly, a time span that is prefixed
+                current time plus the specified time
+                span. Correspondingly, a time span that is prefixed
                 with <literal>-</literal> is evaluated to the current
                 time minus the specified time span. Instead of
-                prefixing the time span with <literal>-</literal> it
-                may also be suffixed with a space and the word
+                prefixing the time span with <literal>+</literal> or
+                <literal>-</literal>, it may also be suffixed with a
+                space and the word <literal>left</literal> or
                 <literal>ago</literal>.</para>
 
+                <para>Finally, a timespan prefixed with
+                <literal>@</literal> is evaluated relative to the UNIX
+                time epoch 1st Jan, 1970, 00:00.</para>
+
                 <para>Examples for valid timestamps and their
                 normalized form (assuming the current time was
                 2012-11-23 18:15:22):</para>
                tomorrow → Fri 2012-11-24 00:00:00
                +3h30min → Fri 2012-11-23 21:45:22
                     -5s → Fri 2012-11-23 18:15:17
-              11min ago → Fri 2012-11-23 18:04:22</programlisting>
+              11min ago → Fri 2012-11-23 18:04:22
+            @1395716396 → Tue 2014-03-25 03:59:56</programlisting>
 
                 <para>Note that timestamps printed by systemd will not
                 be parsed correctly by systemd, as the timezone
                 specified, it should consist of one or more English
                 language weekday names, either in the abbreviated
                 (Wed) or non-abbreviated (Wednesday) form (case does
-                not matter), separated by commas. Specifying two weekdays
-                separated by "-" refers to a range of continuous
-                weekdays. "," and "-" may be combined freely.</para>
+                not matter), separated by commas. Specifying two
+                weekdays separated by <literal>-</literal> refers to a
+                range of continuous weekdays. <literal>,</literal> and
+                <literal>-</literal> may be combined freely.</para>
 
                 <para>In the date and time specifications, any
-                component may be specified as "*" in which case any
-                value will match. Alternatively, each component can be
-                specified as list of values separated by
-                commas. Values may also be suffixed with "/" and a
-                repetition value, which indicates that the value and
-                all values plus multiples of the repetition value are
-                matched.</para>
+                component may be specified as <literal>*</literal> in
+                which case any value will match. Alternatively, each
+                component can be specified as a list of values separated
+                by commas. Values may also be suffixed with
+                <literal>/</literal> and a repetition value, which
+                indicates that the value and all values plus multiples
+                of the repetition value are matched.</para>
 
                 <para>Either time or date specification may be
                 omitted, in which case the current day and 00:00:00 is
                 implied, respectively. If the second component is not
-                specified ":00" is assumed.</para>
+                specified, <literal>:00</literal> is assumed.</para>
 
                 <para>Timezone names may not be specified.</para>
 
                 <para>The special expressions
                 <literal>hourly</literal>, <literal>daily</literal>,
-                <literal>monthly</literal> and <literal>weekly</literal>
-                may be used as calendar events which refer to
-                <literal>*-*-* *:00:00</literal>, <literal>*-*-*
-                00:00:00</literal>, <literal>*-*-01 00:00:00</literal> and
-                <literal>Mon *-*-* 00:00:00</literal>,
-                respectively.</para>
+                <literal>monthly</literal>, <literal>weekly</literal>,
+                and <literal>yearly</literal> or
+                <literal>annually</literal> may be used as calendar
+                events which refer to
+                <literal>*-*-* *:00:00</literal>,
+                <literal>*-*-* 00:00:00</literal>,
+                <literal>*-*-01 00:00:00</literal>,
+                <literal>Mon *-*-* 00:00:00</literal>, and
+                <literal>*-01-01 00:00:00</literal> respectively.
+                </para>
 
                 <para>Examples for valid timestamps and their
                 normalized form:</para>
@@ -270,6 +281,8 @@ Wed-Sat,Tue 12-10-15 1:2:3 → Tue-Sat 2012-10-15 01:02:03
                      daily → *-*-* 00:00:00
                    monthly → *-*-01 00:00:00
                     weekly → Mon *-*-* 00:00:00
+                    yearly → *-01-01 00:00:00
+                  annually → *-01-01 00:00:00
                      *:2/3 → *-*-* *:02/3:00</programlisting>
 
                   <para>Calendar events are used by timer units, see