diff options
| author | Michael Forney <mforney@mforney.org> | 2017-09-24 12:04:42 -0700 |
|---|---|---|
| committer | Michael Forney <mforney@mforney.org> | 2017-09-25 19:23:06 -0700 |
| commit | 86595977d761baa67c1462efd59a6404b56205ad (patch) | |
| tree | 515fbfbb2154f288e53eb3a94b6191b7e1d95b57 /pkg/tz/tzdata.awk | |
| parent | ba94a8513d9a0aadb3f2c834c74b64aa644c61e8 (diff) | |
tz: Write tzdata hash script in lua
This should make it easier to support the users `config.fs`.
Diffstat (limited to 'pkg/tz/tzdata.awk')
| -rw-r--r-- | pkg/tz/tzdata.awk | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/pkg/tz/tzdata.awk b/pkg/tz/tzdata.awk deleted file mode 100644 index e7b48085..00000000 --- a/pkg/tz/tzdata.awk +++ /dev/null @@ -1,26 +0,0 @@ -# usage: awk -f tzdata.awk repo=out/root.git out=out/pkg/tz/zoneinfo [file...] - -function run(cmd) { - status = system(cmd) - if (status != 0) - exit status -} - -BEGIN { - cmdfmt = "rc ./scripts/hash.rc %s %s share/zoneinfo/%s %s" -} - -FNR == 1 { - run(sprintf("zic -d %s %s", out, FILENAME)) -} - -$1 == "Link" { - s = $3 - gsub(/[^\/]+/, "..", s) - s = substr(s, 1, length(s) - 2) $2 - run(sprintf(cmdfmt, repo, 120000, $3, s)) -} - -$1 == "Zone" { - run(sprintf(cmdfmt, repo, 100644, $2, out "/" $2)) -} |
