Fix up update-tzdata.sh so it'll run

On my Debian Sid system, the readlink commands return the empty string.
Given we use these as output files and the files to fetch, I figure
that using hardcoded names is better.
This commit is contained in:
Andrew Ruthven 2021-01-24 23:22:57 +13:00
parent 9252a329d2
commit b15e320fb7

View File

@ -1,9 +1,9 @@
#!/bin/sh
wget --continue 'ftp://ftp.iana.org/tz/tz*.tar.gz'
set -e
TZCODEFILE="`readlink tzcode-latest.tar.gz`"
TZDATAFILE="`readlink tzdata-latest.tar.gz`"
TZCODEFILE="tzcode-latest.tar.gz"
TZDATAFILE="tzdata-latest.tar.gz"
# if [ ! -f $TZCODEFILE ]; then
(
@ -21,5 +21,6 @@ TZDATAFILE="`readlink tzdata-latest.tar.gz`"
)
# fi
# From: https://github.com/libical/vzic
vzic --pure --olson-dir tzdata --output-dir vtimezones
echo "Olson `echo $TZDATAFILE | cut -f1 -d.`" >vtimezones/primary-source