diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2012-11-09 18:12:22 -0800 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2012-11-09 18:12:22 -0800 |
commit | 89a60086d33916dc355325525b85381033b7e86e (patch) | |
tree | bc425224ed17cc096918e569a1f643c4b1e86e5c /tzselect.ksh | |
parent | bd6e304281d875b9173dbd535f513908cd3bbd22 (diff) | |
download | tz-89a60086d33916dc355325525b85381033b7e86e.tar.gz |
Output version info in a more-typical format.
E.g., "zic (tzcode) 2012i" instead of "tzcode2012i".
Thread started by Joseph S. Myers in
<http://mm.icann.org/pipermail/tz/2012-November/018439.html>.
* Makefile (PACKAGE): New macro.
(version.h, tzselect): New constant PKGVERSION, derived from PACKAGE.
(tzselect): TZVERSION is now simply VERSION, since PACKAGE is also
output.
* tzselect.ksh (PKGVERSION): New var, which Makefile substitutes for.
(--usage, --version): Exit with nonzero status if we can't
output the help or version number.
* tzselect.ksh (--version):
* zdump.c, zic.c (main):
Output versions like this: "zdump (tzcode) 2012i".
Diffstat (limited to 'tzselect.ksh')
-rw-r--r-- | tzselect.ksh | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tzselect.ksh b/tzselect.ksh index 279bdf2..51bafc1 100644 --- a/tzselect.ksh +++ b/tzselect.ksh @@ -1,5 +1,6 @@ #!/bin/bash +PKGVERSION='(tzcode) ' TZVERSION=see_Makefile # Ask the user about the time zone, and output the resulting TZ value to stdout. @@ -45,12 +46,12 @@ Select a time zone interactively. Report bugs to tz@iana.org. EOF - exit 0 + exit elif [ "$1" = "--version" ]; then cat <<EOF -tzselect $TZVERSION +tzselect $PKGVERSION$TZVERSION EOF - exit 0 + exit fi # Make sure the tables are readable. |