How to get tz database version?

42 views
Skip to first unread message

Susanne Meyer

unread,
Mar 29, 2016, 9:00:28 PM3/29/16
to cctz
Hi there,

using cctz on Windows, is there a cctz function to get the tz database version number which is (manually) installed on the computer (for example 'tz data v. 2015a' or 'tz data v. 2016c')? I didn't find such cctz function or did I overlooked it?

If you want to keep the tz database up to date on your computer the version number is a usefull information. Looking into the tz database files with an editor won't work because the files are compiled.

If cctz doesn't got such function yet, could you please add it?

Susan


Bradley White

unread,
Mar 29, 2016, 11:44:37 PM3/29/16
to Susanne Meyer, CCTZ
On Tue, Mar 29, 2016 at 9:00 PM, 'Susanne Meyer' via cctz <cc...@googlegroups.com> wrote:
Hi there,

Hi Susan,
 
using cctz on Windows, is there a cctz function to get the tz database version number which is (manually) installed on the computer (for example 'tz data v. 2015a' or 'tz data v. 2016c')? I didn't find such cctz function or did I overlooked it?

No, there is no such function.
 
If you want to keep the tz database up to date on your computer the version number is a usefull information. Looking into the tz database files with an editor won't work because the files are compiled.

Even if you could look into the compiled files, or even if you looked at the source files, you still couldn't answer the question as those files don't contain any indication of the database version.
 
If cctz doesn't got such function yet, could you please add it?

The database version, like "2016c", is purely a function of how/when the files were packaged, so tracking the version has to be handled at that level.  On a Linux system this is typically handled by some kind of package manager.  For example, on my Ubuntu system, ...

$ dpkg-query -W tzdata 
tzdata  2016c-0ubuntu0.14.04

So, it is out of the hands of the cctz library.

All that said, I have petitioned the database maintainers to support some way to brand a compiled file with a version string (and possibly the zone name too), but nothing has come of it yet.

sorry,
Bradley
Reply all
Reply to author
Forward
0 new messages