File: units.texi

package info (click to toggle)
dateutils 0.4.11-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,228 kB
  • sloc: ansic: 22,598; makefile: 1,771; yacc: 202; sh: 168; lex: 108
file content (25 lines) | stat: -rw-r--r-- 729 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
@section Specifying durations

Some tools (@samp{dadd}, @samp{dseq}) need durations as their input.
Durations are generally incompatible with input formats as specified by
@samp{-i|--input-format} and (at the moment) the input syntax is fixed.

The general format is @samp{[+-]Nunit} where @samp{+} or @samp{-} is the
sign, @samp{N} a number, and @samp{unit} the unit as discussed below.

Units:
@verbatim
  s  seconds
  m  minutes
  h  hours
  rs real-life seconds, as in including leap second transitions

  d  days
  b  business days
  mo months
  y  years
@end verbatim

For historical reasons, we used to accept @samp{m} in the context of
date-only input as a qualifier for months.  As of 0.4.4, this is no
longer the case.