[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#118396: dpkg-parsechangelog should accept ISO date format

Package: dpkg
Version: 1.9.18
Severity: wishlist
Tags: patch

I would prefer the international (ISO) date format instead
of the US american date format.

The regular expression in scripts/cl-debian.pl, line 112,
should be:

# RFC 822 or ISO 8601 date format
    } elsif (m/^ \-\- (.*) <(.*)>  ((\w+\,\s*)?((\d{1,2}\s+\w+\s+\d{4}\s+\d{1,2}:\d\d:\d\d\s+)|(\d\d\d\d-\d\d-\d\d[T\s+]\d\d:\d\d:\d\d\s*))[-+]\d{4}(\s+\([^\\\(\)]\))?)$/) {

This allows formats like:
"2001-11-01 11:22:33 +0000" (like ISO, but readable),
"2001-11-01T11:22:33+0000" (like `date --iso=seconds'), or
"Thu,  1 Nov 2001 11:22:33 +0000" (RFC).

I will send a patch for dpkg-dev-el, so that Emacs will be
able to generate the ISO format.

Cheers, WB

Reply to: