Bug#788111: dateutils: Problems with input and output formats

2018-02-02 Thread Thorsten Alteholz

Hi Andrew,

in your first example you use %y. According to the man page this is:
  %y  The year without a century (range 00 to 99)
So with "2015" at the beginning of the date, there are really two digits too 
much and the error is correct.

The %d-problem seems to be fixed in the latest version now.

  Thorsten



Bug#788111: dateutils: Problems with input and output formats

2015-06-08 Thread Andrew Gallagher
Package: dateutils
Version: 0.3.1-1.1
Severity: normal

Dear Maintainer,

The input format %y does not work as per the documentation. Only %Y works:

andrewg@xen:~$ dateutils.ddiff -i %y%m%d%H%M%S -f %S now 20150407075744
ddiff: cannot make sense of `20150407075744' using the given input formats
andrewg@xen:~$ dateutils.ddiff -i %Y%m%d%H%M%S -f %S now 20150407075744
-5393469


Also, the output format %d doesn't work when used by itself (but does work in
combination with other format specifiers, strangely):

andrewg@xen:~$ dateutils.ddiff -i %Y%m%d%H%M%S -f %d %S 20150407075744 now
62 36520
andrewg@xen:~$ dateutils.ddiff -i %Y%m%d%H%M%S -f %d 20150407075744 now
0
andrewg@xen:~$ dateutils.ddiff -i %Y%m%d%H%M%S -f %S 20150407075744 now
5393331



-- System Information:
Debian Release: 8.1
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 4.0.4-x86-linode75 (SMP w/8 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages dateutils depends on:
ii  libc6  2.19-18

dateutils recommends no packages.

dateutils suggests no packages.

-- no debconf information


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org